| predictClasses,CohortList,ClinicalModel-method {PDATK} | R Documentation |
CohortList of
SurvivalExperment Objects.Use a Clinical GLM to Predict Classes for a CohortList of
SurvivalExperment Objects.
## S4 method for signature 'CohortList,ClinicalModel' predictClasses(object, model, ..., na.action = "na.exclude", type = "response")
object |
A |
model |
A trained |
... |
Fall through parameters to |
na.action |
The |
type |
The |
A CohortList with the model predictions in the colData
slot as clinical_prob_good for each SurvivalExperiment, and the
model in the metadata as predictionModel.
data(sampleClinicalModel)
data(sampleCohortList)
# Set parallelization settings
BiocParallel::register(BiocParallel::SerialParam())
# Train Model
trainedClinicalModel <- trainModel(sampleClinicalModel)
# Make predictions
ClinicalPredCohortList <- predictClasses(sampleCohortList[c('PCSI', 'TCGA')],
model=trainedClinicalModel)
head(colData(ClinicalPredCohortList[[1]]))