
Project cell group scores onto trained NMF latent factors
project_factors.RdApplies the positive-negative split to new samples and projects them onto the latent space learned during training using the Moore-Penrose pseudoinverse of the scaled basis matrix W.
Arguments
- latent_spaces
A list returned by
compute.latent_factors(), containing at minimumW(features x rank),rank, and the RcppML model object withnmf_model$dscaling vector.- scores_test
A samples x cell groups matrix of signed CCA composite scores for the test cohort. Column names must match those used in training (before the _pos/_neg suffix was added).