extractGC {DMRcaller} | R Documentation

## Extract GC

### Description

This function extracts GC sites in the genome

### Usage

    extractGC(methylationData, genome, contexts = c("ALL", "CG", "CHG", "CHH"))

### Arguments

`methylationData` | the methylation data stored as a `GRanges` object with four metadata columns (see `methylationDataList`).
`genome` | a BSgenome with the DNA sequence of the organism
`contexts` | the context in which the DMRs are computed (`"ALL"`, `"CG"`, `"CHG"` or `"CHH"`).

### Value

the a subset of `methylationData` consisting of all GC sites.

### Author(s)

Ryan Merritt

### Examples

    ## Not run:
    # load the genome sequence
    if(!require("BSgenome.Athaliana.TAIR.TAIR9", character.only = TRUE)){
      if (!requireNamespace("BiocManager", quietly=TRUE))
          install.packages("BiocManager")
      BiocManager::install("BSgenome.Athaliana.TAIR.TAIR9")
    }
    library(BSgenome.Athaliana.TAIR.TAIR9)

    # load the methylation data
    data(methylationDataList)

    methylationDataWTGpCpG <- extractGC(methylationDataList[["WT"]],
                                        BSgenome.Athaliana.TAIR.TAIR9,
                                        "CG")

    ## End(Not run)

[Package DMRcaller version 1.18.0 Index]