Some scripts to prepare ontology long table for enrichment and GSEA analysis.
This pipeline requires these dependencies.
python3 -m pip install pandas owlready2 retrying openpyxlfollowing data require manually download.
Sitalica_312_v2.2.annotation_info.txt: from JGI Sitalica annotationATH_GO_GOSLIM.txt: from TAIR Download GO_and_PO_Annotations
For TAIR gene search results, in TAIR Gene Search page, use different chromosome as filter, after clicking "Submit Query" bottom and search results displayed, click "Download All" bottom to download result tsv file.
A example of enrichment analysis using clusterProfiler.
install.packages("readxl")
install.packages("BiocManager")
BiocManager::install("clusterProfiler")term_to_gene = readr::read_tsv("results/oryzabase.RAP_GO.term_to_gene.tsv.gz", col_names=F)
term_to_description = readr::read_tsv("results/oryzabase.RAP_GO.term_to_description.tsv.gz", col_names=F)
gene = c("Os01g0118100", "Os01g0549700", "Os02g0710800", "Os03g0108600", "Os03g0158200", "Os03g0746500")
universe = NULL
enrich_res = clusterProfiler::enricher(
gene=gene,
universe=universe,
TERM2GENE=term_to_gene,
TERM2NAME=term_to_description
)
write.csv(as.data.frame(enrich_res), "enrich_res.csv")
svg("demo_dotplot.svg")
clusterProfiler::dotplot(enrich_res)
dev.off()