MethylSet-class {minfi} | R Documentation

## MethylSet instances

### Description

This class holds preprocessed data for Illumina methylation microarrays.

### Usage

    ## Constructor

    MethylSet(Meth = new("matrix"), Unmeth = new("matrix"),
              annotation = "", preprocessMethod = "", ...)

    ## Data extraction / Accessors

    ## S4 method for signature 'MethylSet'
    getMeth(object)
    ## S4 method for signature 'MethylSet'
    getUnmeth(object)
    ## S4 method for signature 'MethylSet'
    getBeta(object, type = "", offset = 0, betaThreshold = 0)
    ## S4 method for signature 'MethylSet'
    getM(object, type = "", ...)
    ## S4 method for signature 'MethylSet'
    getCN(object, ...)
    ## S4 method for signature 'MethylSet'
    getManifest(object)
    ## S4 method for signature 'MethylSet'
    preprocessMethod(object)
    ## S4 method for signature 'MethylSet'
    annotation(object)
    ## S4 method for signature 'MethylSet'
    pData(object)
    ## S4 method for signature 'MethylSet'
    sampleNames(object)
    ## S4 method for signature 'MethylSet'
    featureNames(object)

    ## Utilities
    dropMethylationLoci(object, dropRS = TRUE, dropCH = TRUE)

### Arguments

`object` | A `MethylSet`.
`Meth` | A matrix of methylation values (between zero and infinity) with each row being a methylation loci and each column a sample.
`Unmeth` | See the `Meth` argument.
`annotation` | An annotation string, optional.
`preprocessMethod` | A `character`, optional.
`type` | How are the values calculated? For `getBeta` setting `type="Illumina"` sets `offset=100` as per Genome Studio. For `getM` setting `type=""` computes M-values as the logarithm of `Meth`/`Unmeth`, otherwise it is computed as the logit of `getBeta(object)`.
`offset` | Offset in the beta ratio, see detail.
`betaThreshold` | Constrains the beta values to be in the inverval betwen `betaThreshold` and 1-`betaThreshold`.
`dropRS` | Should SNP probes be dropped?
`dropCH` | Should CH probes be dropped
`...` | For the constructor, additional arguments to be passed to `SummarizedExperiment`; of particular interest are `colData`, `rowData` and `metadata`. For `getM` these values gets passed onto `getBeta`.

### Details

This class inherits from `eSet`. Essentially the class is a representation of a `Meth` matrix and a `Unmeth` matrix linked to a `pData` data frame.

In addition, an annotation and a preprocessMethod slot is present. The annotation slot describes the type of array and also which annotation package to use. The preprocessMethod slot describes the kind of preprocessing that resulted in this dataset.

A `MethylSet` stores `meth` and `Unmeth`. From these it is easy to compute Beta values, defined as

Beta = Meth / (Meth + Unmeth + offset)

The offset is chosen to avoid dividing with small values. Illumina uses a default of 100. M-values (an unfortunate bad name) are defined as

M = logit(Beta) = log( Meth / Unmeth )

This formula has problems if either Meth or Unmeth is zero. For this reason, we can use `betaThreshold` to make sure Beta is neither 0 nor 1, before taken the logit. What makes sense for the `offset` and `betaThreshold` depends crucially on how the data was preprocessed. Do not expect the default values to be particular good.

### Value

An object of class `MethylSet` for the constructor.

### Constructor

Instances are constructed using the `MethylSet` function with the arguments outlined above.

### Accessors

In the following code, `object` is a `MethylSet`.

`getMeth(object)`, `getUnmeth(object)`

  Get the Meth or the Unmeth matrix

`getBeta(object)`

  Get Beta, see details.

`getM(object)`

  get M-values, see details.

`getCN(object)`

  get copy number values which are defined as the sum of the methylation and unmethylation channel.

`getManifest(object)`

  get the manifest associated with the object.

`preprocessMethod(object)`

  Get the preprocess method `character`.

### Utilities

In the following code, `object` is a `MethylSet`.

`dropMethylationLoci`(object)

  A unifed interface to removing methylation loci. You can drop SNP probes (probes that measure SNPs, not probes containing SNPs) or CH probes (non-CpG methylation).

`combine`:

  Combines two different `MethylSet`, eventually using the `combine` method for `eSet`.

### Author(s)

Kasper Daniel Hansen khansen@jhsph.edu

### See Also

`eSet` for the basic class structure. Objects of this class are typically created from an `RGChannelSet` using `preprocessRaw` or another preprocessing function.

### Examples

      showClass("MethylSet")

[Package minfi version 1.28.4 Index]