YuLab-SMU / DOSE

:mask: Disease Ontology Semantic and Enrichment analysis
https://yulab-smu.top/biomedical-knowledge-mining-book/
117 stars 36 forks source link

compareCluster error #19

Closed Georgewiggins closed 7 years ago

Georgewiggins commented 7 years ago

Hi,

I am trying to compare 3 enrichment pathway analysis together but keep getting an error, my code works with your example data gcSample but not with my data.

I have provided a subset of my data which produces the same error.

list(c("3169", "152015", "51442", "644945", "644945", "203413", 
"56521", "2019", "10232", "2203", "1602", "22901", "10644", "135293", 
"3696", "5890", "9", "5457", "8416", "3595", "135295", "2173", 
"11254", "9568", "30812", "1131", "64225", "149563", "399694", 
"79818", "81706", "132946", "57580", "5596", "2001", "2950", 
"339761", "25902", "57480", "5918", "154091", "6542", "6284", 
"139285", "7031", "25803", "6422", "2707", "9469", "284467"), 
    c("3169", "7368", "25803", "419", "2203", "203413", "93273", 
    "23158", "135295", "144568", "222171", "6663", "284467", 
    "367", "3868", "80129", "9654", "337977", "2019", "8645", 
    "11254", "5653", "81706", "2707", "6769", "101927016", "145837", 
    "401585", "9911", "57758", "29113", "27160", "140578", "8537", 
    "11341", "10974", "9568", "3595", "401535", "10164", "4240", 
    "8326", "10103", "25937", "54149", "51678", "5806", "8190", 
    "84072", "57348"), c("1029", "51442", "2019", "1029", "2296", 
    "3868", "8614", "2568", "6663", "2173", "8614", "7368", "419", 
    "57180", "8190", "29968", "2173", "3854", "10644", "23704", 
    "7545", "5918", "84223", "51442", "9568", "10643", "3169", 
    "3887", "57348", "10884", "5653", "55612", "10232", "2625", 
    "2001", "3854", "11341", "5806", "23362", "1824", "53335", 
    "8645", "1825", "7494", "3620", "5918", "221061", "85377", 
    "81611", "9654"))

x<-compareCluster(geneCluster = x.test, fun = "enrichPathway", pvalueCutoff = 1, qvalueCutoff =1)

The error I get is

The following `from` values were not present in `x`: .id
Error in `$<-.data.frame`(`*tmp*`, "Cluster", value = integer(0)) : 
  replacement has 0 rows, data has 143
GuangchuangYu commented 7 years ago

the input should be a named list.