countsRemoveSV: Apply SVA to transformed count data and return the...

View source: R/sva.R

countsRemoveSVR Documentation

Apply SVA to transformed count data and return the transformed matrix removing the effect of surrogate variables

Description

Apply SVA to transformed count data and return the transformed matrix removing the effect of surrogate variables

Usage

countsRemoveSV(
  counts,
  designMatrix,
  transformFunc = function(counts, designMatrix) voom(counts, designMatrix)$E
)

Arguments

counts

A matrix of counts

designMatrix

Design matrix

transformFunc

A function to transform the count data

Value

The expression matrix, with SV effects removed

Examples


exCounts <- matrix(rpois(12000, 10), nrow=2000, ncol=6)
exCounts[1:100, 2:3] <- exCounts[1:100,2:3]+20
exDesign <- model.matrix(~gl(2,3))
head(countsRemoveSV(exCounts, designMatrix=exDesign))


bedapub/ribiosNGS documentation built on Feb. 10, 2025, 12:34 a.m.