covariates<-,Classifier-method | R Documentation |
Add covariate data into the classifier.
covariates(obj) <- value
obj |
An object of the class Classifier. |
value |
A numeric vector or a matrix. |
If the input is a vector, the elements must be named and these names will be used to identify variables.
If the input is a matrix, it must have named rows and named columns that
will be matched with sample identities in profiles()
.
Updates the Classifier object. Any previous data are discarded.
# Simulated data. simu <- bcellALL(5) # Predict subtypes without covariates. cls <- classifier(verbose = FALSE) profiles(cls) <- simu$counts primary <- predictions(cls)[[1]] print(primary[,c("LABEL","PROX","EXCL")]) # Predict subtypes with covariates. cls <- classifier(verbose = FALSE) covariates(cls) <- simu$metadata profiles(cls) <- simu$counts primary <- predictions(cls)[[1]] print(primary[,c("LABEL","PROX","EXCL")])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.