set.covariates.sva {RnBeads} | R Documentation

## set.covariates.sva

### Description

Adds the results of Surrogate Variable Analysis (SVA) to an RnBSet

### Usage

    set.covariates.sva(rnb.set, sva.obj)

### Arguments

`rnb.set` | The `RnBSet` object to which the results should be added
`sva.obj` | An object of class `SvaResult` as returned by `rnb.execute.sva`.

### Value

The modified `RnBSet`. Note that the association information will not be stored.

### Author(s)

Fabian Mueller

### Examples

    library(RnBeads.hg19)
    data(small.example.object)
    logger.start(fname=NA)
    sva.obj <- rnb.execute.sva(rnb.set.example,c("Sample_Group","Treatment"),numSVmethod="be")
    sva.obj$sva.performed
    sva.obj$num.components
    rnb.set.mod <- set.covariates.sva(rnb.set.example, sva.obj)
    has.covariates.sva(rnb.set.example,"Sample_Group")
    has.covariates.sva(rnb.set.mod,"Sample_Group")

[Package RnBeads version 2.4.0 Index]