l-magnificence / Mime

Machine learning-based integration model with elegant performance
Other
57 stars 10 forks source link

Error in `[.data.frame`(hmdat[[1]], , samorder) : undefined columns selected #41

Open 123wanguang123456 opened 1 month ago

123wanguang123456 commented 1 month ago

When I run this command: immuno_heatmap(res, devo, model_name="RSF + StepCox[both]", dataset="train")

Error in `[.data.frame`(hmdat[[1]], , samorder) : 
                undefined columns selected

         Do you know the cause of this error?

Loading required package: viridisLite Loading required package: grid

ComplexHeatmap version 2.20.0 Bioconductor page: http://bioconductor.org/packages/ComplexHeatmap/ Github page: https://github.com/jokergoo/ComplexHeatmap Documentation: http://jokergoo.github.io/ComplexHeatmap-reference

If you use it in published research, please cite either one:

The new InteractiveComplexHeatmap package can directly export static complex heatmaps into an interactive Shiny app with zero effort. Have a try!

This message can be suppressed by: suppressPackageStartupMessages(library(ComplexHeatmap))

! pheatmap() has been masked by ComplexHeatmap::pheatmap(). Most of the arguments in the original pheatmap() are identically supported in the new function. You can still use the original function by explicitly calling pheatmap::pheatmap().

Attaching package: ‘ComplexHeatmap’

The following object is masked from ‘package:pheatmap’:

pheatmap

                Error in `[.data.frame`(hmdat[[1]], , samorder) : 
                undefined columns selected
l-magnificence commented 1 month ago

I think this is not the error of function but the input data. You can check the input data and make sure defined columns are existed in your object res and devo.

123wanguang123456 commented 1 month ago

@l-magnificence Dear Author,

My input data(train) does not exist in "res", is this correct? The command I used was: res <- ML.Dev.Prog.Sig(train_data = trainlist$train, list_train_vali_Data = trainlist, unicox.filter.for.candi = T, unicox_p_cutoff = 0.05, candidate_genes = genelist, mode = 'all',nodesize =5,seed = 5201314,cores_for_parallel=1 )