Last active
April 9, 2018 05:56
-
-
Save carushi/cc82d623af80d633539022aabbc32d2a to your computer and use it in GitHub Desktop.
To resolve an error when running ReactomePA (Error in levels <- ... factor level is duplicated Calls: ... fortify.enrichResult -> fortify.internal -> factor
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fc_gene <- enrichPathway(gene=unique(names(fc)), pvalueCutoff=0.1, organism = "mouse", readable=T) | |
fc_gene | |
attributes(fc_gene) | |
index <- sapply(seq(1, length(fc_gene$Description)), function(x){return(which(fc_gene$Description == fc_gene$Description[x])[1] == x)}) | |
attr(fc_gene, "result") <- attr(fc_gene, "result")[index,] | |
dotplot(fc_gene, showCategory=15) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment