Skip to content

What are the differences between vars.to.regress and latent.vars? Should I use both for a variable? #4259

Discussion options

You must be logged in to vote

vars.to.regress in ScaleData() and SCTransform() specifies variables to regress out of the scaled data or sctransform residuals. These values are typically used for PCA dimension reduction, and so would prevent those variables that are regressed out from contributing much to the PCA.

latent.vars in FindMarkers() specifies latent variables to include in the differential expression model. The normalized data, rather than scaled data or sctransform residuals is typically used for differential expression.

If I want to reduce the effect of a certain set of genes, should I specify the percent of counts from these genes in both steps?

Reduce the effect on what exactly? If you have a set of gen…

Replies: 1 comment 6 replies

Comment options

You must be logged in to vote
6 replies
@timoast
Comment options

@denvercal1234GitHub
Comment options

@timoast
Comment options

@denvercal1234GitHub
Comment options

@denvercal1234GitHub
Comment options

Answer selected by timoast
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #4234 on March 19, 2021 18:34.