[ChIPseeker] Unable to perform gene ontology analysis
0
0
Entering edit mode
Henry ▴ 10
@40e2dbef
Last seen 5 months ago
United Kingdom

Hi there! I'm trying to perform gene ontology analysis comparing tumor and normal samples. There are about 250 and 350 differentially enriched peaks in the tumor and normal samples respectively.

However, there are 0 enriched terms found when I performed the enrichGO() function on the tumor and normal gene lists containing the respective entrez ID of the differentially enriched genes.

May I ask if anyone encountered a similar issue and if there are any ways to resolve this please?

Thank you!

samplefiles <- list.files("/path/diffbind_enriched_bed", 
                          pattern= ".bed",
                          full.names=T) 

samplefiles <- as.list(samplefiles) 

names(samplefiles) <- c("Normal", "Tumor") 

txdb <- TxDb.Hsapiens.UCSC.hg38.knownGene

peakAnnoList <- lapply(samplefiles, 
                       annotatePeak, 
                       TxDb=txdb,
                       tssRegion=c(-1000, 1000), 
                       verbose=FALSE) 

# ====================== Retrieve annotations ======================

normal_annot <- data.frame(peakAnnoList[["Normal"]]@anno)


tumor_annot <- data.frame(peakAnnoList[["Tumor"]]@anno)

# ====== Obtain the gene symbols from the annotations ======

entrez_normal <- normal_annot$geneId
annotations_edb_normal <- AnnotationDbi::select(EnsDb.Hsapiens.v86, 
                                                keys = entrez_normal, 
                                                columns = c("GENENAME"), 
                                                keytype = "ENTREZID") 

normal_annot %>% 
  left_join(annotations_edb_normal, by=c("geneId"="ENTREZID")) %>% 
  write.table(file="results/chipseeker/Normal_peak_annotation.txt", sep="\t", quote=F, row.names=F)

entrez_tumor <- tumor_annot$geneId
annotations_edb_tumor <- AnnotationDbi::select(EnsDb.Hsapiens.v86, 
                                                keys = entrez_tumor, 
                                                columns = c("GENENAME"), 
                                                keytype = "ENTREZID")

annotations_edb_tumor$ENTREZID <- as.character(annotations_edb_tumor$ENTREZID)

tumor_annot %>% 
  left_join(annotations_edb_tumor, by=c("geneId"="ENTREZID")) %>% 
  write.table(file="results/chipseeker/Tumor_peak_annotation.txt", sep="\t", quote=F, row.names=F)


# ================================= GO enrichment analysis ==============================================

# Over-representation analysis
ego_normal <- enrichGO(gene = entrez_normal, 
                keyType = "ENTREZID", 
                OrgDb = org.Hs.eg.db, 
                ont = "BP", 
                pAdjustMethod = "BH", 
                qvalueCutoff = 0.05, 
                readable = TRUE)

> ego_normal
# over-representation test
#
#...@organism    Homo sapiens 
#...@ontology    BP 
#...@keytype     ENTREZID 
#...@gene    chr [1:350] "54541" "2027" "79633" "5097" "81565" "54508" "7580" "5048" "494470" "143425" "124900546" "2274" ...
#...pvalues adjusted by 'BH' with cutoff <0.05 
#...0 enriched terms found
#...Citation
 T Wu, E Hu, S Xu, M Chen, P Guo, Z Dai, T Feng, L Zhou, W Tang, L Zhan, X Fu, S Liu, X Bo, and G Yu.
 clusterProfiler 4.0: A universal enrichment tool for interpreting omics data.
 The Innovation. 2021, 2(3):100141 

ego_tumor <- enrichGO(gene = entrez_tumor,
                       keyType = "ENTREZID", 
                       OrgDb = org.Hs.eg.db, 
                       ont = "BP", 
                       pAdjustMethod = "BH", 
                       qvalueCutoff = 0.05, 
                       readable = TRUE)
> ego_tumor
#
# over-representation test
#
#...@organism    Homo sapiens 
#...@ontology    BP 
#...@keytype     ENTREZID 
#...@gene    chr [1:240] "9684" "587" "341" "340371" "439965" "2743" "387893" "29894" "57142" "8733" "4796" "10485" "8644" ...
#...pvalues adjusted by 'BH' with cutoff <0.05 
#...0 enriched terms found
#...Citation
 T Wu, E Hu, S Xu, M Chen, P Guo, Z Dai, T Feng, L Zhou, W Tang, L Zhan, X Fu, S Liu, X Bo, and G Yu.
 clusterProfiler 4.0: A universal enrichment tool for interpreting omics data.
 The Innovation. 2021, 2(3):100141 

sessionInfo( )
R version 4.3.3 (2024-02-29)
Platform: aarch64-apple-darwin20 (64-bit)
Running under: macOS Sonoma 14.1.2

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib 
LAPACK: /Library/Frameworks/R.framework/Versions/4.3-arm64/Resources/lib/libRlapack.dylib;  LAPACK version 3.11.0

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

tzcode source: internal

attached base packages:
[1] stats4    stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] org.Hs.eg.db_3.18.0                      dplyr_1.1.4                             
 [3] ChIPseeker_1.38.0                        clusterProfiler_4.10.1                  
 [5] EnsDb.Hsapiens.v86_2.99.0                ensembldb_2.26.0                        
 [7] AnnotationFilter_1.26.0                  TxDb.Hsapiens.UCSC.hg38.knownGene_3.18.0
 [9] GenomicFeatures_1.54.4                   AnnotationDbi_1.64.1                    
[11] Biobase_2.62.0                           GenomicRanges_1.54.1                    
[13] GenomeInfoDb_1.38.8                      IRanges_2.36.0                          
[15] S4Vectors_0.40.2                         BiocGenerics_0.48.1                     

loaded via a namespace (and not attached):
  [1] splines_4.3.3                           BiocIO_1.12.0                          
  [3] ggplotify_0.1.2                         bitops_1.0-7                           
  [5] filelock_1.0.3                          tibble_3.2.1                           
  [7] polyclip_1.10-6                         XML_3.99-0.16.1                        
  [9] lifecycle_1.0.4                         mixsqp_0.3-54                          
 [11] lattice_0.22-6                          MASS_7.3-60.0.1                        
 [13] systemPipeR_2.8.0                       magrittr_2.0.3                         
 [15] limma_3.58.1                            plotrix_3.8-4                          
 [17] yaml_2.3.8                              cowplot_1.1.3                          
 [19] DBI_1.2.2                               RColorBrewer_1.1-3                     
 [21] abind_1.4-5                             ShortRead_1.60.0                       
 [23] zlibbioc_1.48.2                         purrr_1.0.2                            
 [25] ggraph_2.2.1                            RCurl_1.98-1.14                        
 [27] yulab.utils_0.1.4                       tweenr_2.0.3                           
 [29] rappdirs_0.3.3                          GenomeInfoDbData_1.2.11                
 [31] enrichplot_1.22.0                       ggrepel_0.9.5                          
 [33] irlba_2.3.5.1                           tidytree_0.4.6                         
 [35] codetools_0.2-20                        DelayedArray_0.28.0                    
 [37] DOSE_3.28.2                             xml2_1.3.6                             
 [39] ggforce_0.4.2                           tidyselect_1.2.1                       
 [41] aplot_0.2.2                             farver_2.1.1                           
 [43] viridis_0.6.5                           matrixStats_1.3.0                      
 [45] BiocFileCache_2.10.2                    jsonlite_1.8.8                         
 [47] GenomicAlignments_1.38.2                tidygraph_1.3.1                        
 [49] bbmle_1.0.25.1                          tools_4.3.3                            
 [51] progress_1.2.3                          TxDb.Hsapiens.UCSC.hg19.knownGene_3.2.2
 [53] treeio_1.26.0                           Rcpp_1.0.12                            
 [55] glue_1.7.0                              gridExtra_2.3                          
 [57] SparseArray_1.2.4                       DESeq2_1.42.1                          
 [59] qvalue_2.34.0                           MatrixGenerics_1.14.0                  
 [61] amap_0.8-19                             withr_3.0.0                            
 [63] numDeriv_2016.8-1.1                     BiocManager_1.30.22                    
 [65] fastmap_1.1.1                           boot_1.3-30                            
 [67] latticeExtra_0.6-30                     fansi_1.0.6                            
 [69] caTools_1.18.2                          digest_0.6.35                          
 [71] truncnorm_1.0-9                         gridGraphics_0.5-1                     
 [73] R6_2.5.1                                colorspace_2.1-0                       
 [75] GO.db_3.18.0                            GreyListChIP_1.34.0                    
 [77] gtools_3.9.5                            jpeg_0.1-10                            
 [79] biomaRt_2.58.2                          RSQLite_2.3.6                          
 [81] utf8_1.2.4                              tidyr_1.3.1                            
 [83] generics_0.1.3                          data.table_1.15.4                      
 [85] rtracklayer_1.62.0                      graphlayouts_1.1.1                     
 [87] prettyunits_1.2.0                       httr_1.4.7                             
 [89] htmlwidgets_1.6.4                       S4Arrays_1.2.1                         
 [91] scatterpie_0.2.2                        pkgconfig_2.0.3                        
 [93] gtable_0.3.4                            blob_1.2.4                             
 [95] hwriter_1.3.2.1                         XVector_0.42.0                         
 [97] shadowtext_0.1.3                        htmltools_0.5.8.1                      
 [99] fgsea_1.28.0                            ProtGenerics_1.34.0                    
[101] scales_1.3.0                            png_0.1-8                              
[103] ggfun_0.1.4                             ashr_2.2-63                            
[105] rstudioapi_0.16.0                       reshape2_1.4.4                         
[107] rjson_0.2.21                            nlme_3.1-164                           
[109] coda_0.19-4.1                           curl_5.2.1                             
[111] bdsmatrix_1.3-7                         cachem_1.0.8                           
[113] stringr_1.5.1                           KernSmooth_2.23-22                     
[115] parallel_4.3.3                          HDO.db_0.99.1                          
[117] restfulr_0.0.15                         apeglm_1.24.0                          
[119] pillar_1.9.0                            grid_4.3.3                             
[121] vctrs_0.6.5                             gplots_3.1.3.1                         
[123] dbplyr_2.5.0                            invgamma_1.1                           
[125] mvtnorm_1.2-4                           cli_3.6.2                              
[127] locfit_1.5-9.9                          compiler_4.3.3                         
[129] Rsamtools_2.18.0                        rlang_1.1.3                            
[131] crayon_1.5.2                            SQUAREM_2021.1                         
[133] labeling_0.4.3                          interp_1.1-6                           
[135] emdbook_1.3.13                          plyr_1.8.9                             
[137] fs_1.6.3                                stringi_1.8.3                          
[139] viridisLite_0.4.2                       deldir_2.0-4                           
[141] BiocParallel_1.36.0                     munsell_0.5.1                          
[143] Biostrings_2.70.3                       lazyeval_0.2.2                         
[145] GOSemSim_2.28.1                         Matrix_1.6-5                           
[147] BSgenome_1.70.2                         patchwork_1.2.0                        
[149] hms_1.1.3                               bit64_4.0.5                            
[151] ggplot2_3.5.0                           KEGGREST_1.42.0                        
[153] statmod_1.5.0                           SummarizedExperiment_1.32.0            
[155] igraph_2.0.3                            memoise_2.0.1                          
[157] ggtree_3.10.1                           fastmatch_1.1-4                        
[159] DiffBind_3.12.0                         bit_4.0.5                              
[161] gson_0.1.0                              ape_5.8
ChIPseeker • 221 views
ADD COMMENT

Login before adding your answer.

Traffic: 812 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6