est_sv {seqgendiff} | R Documentation |
Estimate the surrogate variables.
Description
This will use either sva
or an SVD on the residuals
of a regression of mat
on design_obs
to estimate the
surrogate variables.
Usage
est_sv(mat, n_sv, design_obs, use_sva = FALSE)
Arguments
mat |
A numeric matrix of RNA-seq counts. The rows index the genes and the columns index the samples. |
n_sv |
The number of surrogate variables. |
design_obs |
A numeric matrix of observed covariates that are NOT to
be a part of the signal generating process. Only used in estimating the
surrogate variables (if |
use_sva |
A logical. Should we use surrogate variable analysis
(Leek and Storey, 2008) using |
Value
A matrix of estimated surrogate variables. The columns index the surrogate variables and the rows index the individuals. The surrogate variables are centered and scaled to have mean 0 and variance 1.
Author(s)
David Gerard