Convert SE to mlr task

Fun_SE_to_taskFunc(SE_obj, param.Y.name, param.covariates,
  param_positive_y_level, task_return_format, task_type)

Arguments

SE_obj

SE class

param.Y.name

Vector of dependent variable name

param.covariates

Vector of coaraiate variable(s) name

param_positive_y_level

if ClassifTask, value (character or numeric) to be considered as the positive factor outcome

Value

mlr's ClassifTask or RegrTask

Details

SE with multiple sub-assays, will include each sub-assay separately.

Either ClassifTask or RegrTask will be returned, based on the type of the param.Y.name variable

Examples

data(airway, package="airway") # RangedSummarizedExperiment airway
#> class: RangedSummarizedExperiment #> dim: 64102 8 #> metadata(1): '' #> assays(1): counts #> rownames(64102): ENSG00000000003 ENSG00000000005 ... LRG_98 LRG_99 #> rowData names(0): #> colnames(8): SRR1039508 SRR1039509 ... SRR1039520 SRR1039521 #> colData names(9): SampleName cell ... Sample BioSample
Fun_SE_to_taskFunc(airway, param.Y.name = 'dex', param.covariates = c('avgLength'), param_positive_y_level = 'trt')
#> Error in SE_obj %>% colData %>% data.frame: could not find function "%>%"