Mercurial > repos > proteore > proteore_clusterprofiler
diff GO-enrich.R @ 26:c8bff18c102b draft
planemo upload commit d884b75cfc292105807c42c58f864d536dc9e431-dirty
| author | proteore |
|---|---|
| date | Wed, 21 Nov 2018 08:22:13 -0500 |
| parents | 3a66e1e65c02 |
| children | 54f8e6f5c59d |
line wrap: on
line diff
--- a/GO-enrich.R Tue Nov 06 08:56:05 2018 -0500 +++ b/GO-enrich.R Wed Nov 21 08:22:13 2018 -0500 @@ -264,12 +264,14 @@ for (onto in ontology) { if (args$go_represent == "true") { ggo<-repartition.GO(gene, orgdb, onto, level, readable=TRUE) + ggo <- as.data.frame(apply(ggo, c(1,2), function(x) gsub("^$|^ $", NA, x))) #convert "" and " " to NA output_path = paste("cluster_profiler_GGO_",onto,".tsv",sep="") write.table(ggo, output_path, sep="\t", row.names = FALSE, quote = FALSE ) } if (args$go_enrich == "true") { ego<-enrich.GO(gene, universe_gene, orgdb, onto, pval_cutoff, qval_cutoff,plot) + ego <- as.data.frame(apply(ego, c(1,2), function(x) gsub("^$|^ $", NA, x))) #convert "" and " " to NA output_path = paste("cluster_profiler_EGO_",onto,".tsv",sep="") write.table(ego, output_path, sep="\t", row.names = FALSE, quote = FALSE ) }
