methylDiff-class {methylKit} | R Documentation

## An S4 class that holds differential methylation information

### Description

This class is designed to hold statistics and locations for differentially methylated regions/bases. It extends `data.frame` class. `calculateDiffMeth` function returns an object with `methylDiff` class.

### Slots

`sample.ids`

  ids/names of samples in a vector

`assembly`

  a name of genome assembly, such as :hg18,mm9, etc

`context`

  numeric vector identifying which samples are which group

`treatment`

  numeric vector identifying which samples are which group

`destranded`

  logical denoting if methylation inormation is destranded or not

`resolution`

  string either 'base' or 'region' defining the resolution of methylation information

`.Data`

  data.frame holding the locations and statistics

### Details

`methylDiff` class extends `data.frame` class therefore providing novice and experienced R users with a data structure that is well known and ubiquitous in many R packages.

### Subsetting

In the following code snippets, `x` is a `methylDiff`. Subsetting by `x[i,]` will produce a new object if subsetting is done on rows. Column subsetting is not directly allowed to prevent errors in the downstream analysis. see ?methylKit[ .

### Coercion

`methylDiff` object can be coerced to `GRanges` object via `as` function.

### Accessors

The following functions provides access to data slots of methylDiff: `getData`,`getAssembly`, `getContext`

### Examples

    data(methylKit)
    library(GenomicRanges)
    my.gr=as(methylDiff.obj,"GRanges")

[Package methylKit version 1.6.3 Index]