Tune nfeat using cross-validation.
CVTune_nfeat(
reference,
assayName = "logcounts",
phenotypes = NULL,
YY = NULL,
ncomp = NULL,
impScores = NULL,
center = TRUE,
scale = FALSE,
nfeatLimits = c(10, 15000),
gridSize = 30,
nfeatV = NULL,
Kfolds = 5,
regMethod = "PCA",
labelCode = "-1,1",
seed = 5202056,
Ncores = 1,
nfeat = NULL
)SingleCellExperiment object.
Character.
Vector.
Matrix.
Integer.
Matrix.
Logic.
Logic.
Vector.
Integer.
Vector.
Integer.
Character.
Character.
Integer. The function sets the seed with withr::local_seed(), so the session's random-number state is restored on exit.
Integer.
Chosen number of features per phenotype, or NULL to
choose after the cross-validation. Only an interactive session can
choose: the function plots the loss and asks.
A list.