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` object. 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 methylDiffDB: - `getData`: get the data slot from the methylKit objects, - `getAssembly`: get assembly of the genome, - `getContext`: get the context of methylation

### Examples

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

[Package methylKit version 1.12.0 Index]