rnb.execute.dreduction {RnBeads} | R Documentation

## rnb.execute.dreduction

### Description

Performs principal component analysis (PCA) and multi-dimensional scaling (MDS) of the samples in the given methylation dataset.

### Usage

    rnb.execute.dreduction(rnb.set, target = "sites")

### Arguments

`rnb.set` | Methylation dataset as an object of type inheriting `RnBSet`. This dataset must contain at least four samples.
`target` | `character` singleton specifying the level of DNA methylation infromation. If this is `"sites"`, the DNA methylation information for the individual sites or probes is analyzed. Otherwise, this should be one of the supported region types, as returned by `rnb.region.types`.

### Details

Row names in the returned matrices are sample identifiers, determined based on the package option `"identifiers.column"`. See RnBeads Options for more information on this option.

### Value

Results of the dimension reduction in the form of a list with the following elements:

`pca`

  Results of the PCA as returned by the function `prcomp`.

`mds`

  List of two elements - `"manhattan"` and `"euclidean"`, each of which is a two-column `matrix` storing the coordinates of the samples in a two-dimensional space. The matrices are computed using the function `isoMDS`.

### Author(s)

Yassen Assenov

### See Also

`rnb.run.exploratory` for running the whole exploratory analysis module

### Examples

    library(RnBeads.hg19)
    data(small.example.object)
    regs <- c("sites", summarized.regions(rnb.set.example))
    dreduction <- function(x) rnb.execute.dreduction(rnb.set.example, x)
    pcoordinates <- lapply(regs, dreduction)
    names(pcoordinates) <- regs
    str(pcoordinates)

[Package RnBeads version 2.12.2 Index]