R/pois_cov_init.R
pois_cov_init.Rd
Initialize data-driven prior covariance matrices based on principal component analysis.
pois_cov_init(
data,
ruv = FALSE,
Fuv = NULL,
rho = NULL,
prop = 1,
seed = 1,
npc = 5,
cutoff = 3
)
“pois.mash” data object, typically created by
calling pois_mash_set_data
.
Logical scalar indicating whether to account for
unwanted variation. Default is FALSE
. If ruv = TRUE
,
Fuv
and rho
must be provided.
J x D matrix of latent factors causing unwanted variation, with features as rows and latent factors as columns.
D x R matrix of effects corresponding to unwanted
variation, such that bias = Fuv %*% rho
.
The proportion by which to take a random subset of genes for prior covariance estimation (useful in case of many genes).
Useful for reproducibility when prop
is less
than 1.
The number of principal components to use.
The threshold for the maximum of absolute values of Z-scores taken across conditions to include as "strong" features used for prior covariance estimation.
A list with initial estimates of prior covariances, and indices of the features (j = 1,...,J) to include in the subsequent ED step.