Question: Warning in bayes fit in MAST GSEA
gravatar for santos22903
7 months ago by
santos229030 wrote:

Hi, I am trying to do gene set enrichment using MAST. I mostly follow the vignette. Here is the code:

        gseaFDR <- 0.05
        bootstrapReplicates <- 3# 3 for temp testing - takes too long
        module <- "BTM" # seems, the only one they have anyway
        packageExt <- system.file("extdata", package='MAST')
        module_file <- list.files(packageExt, pattern = module, full.names = TRUE)
        gene_set <- getGmt(module_file) # getting GeneSetCollection
        gene_ids <- geneIds(gene_set) # extracting gene IDs
        ## gene sets for human genes; to compare with mouse, remove all capitalization
        sets_indices <- limma::ids2indices(sapply(gene_ids,tolower), tolower(mcols(scaObj)$symbol))
        start_time <- Sys.time()
        boots <- bootVcov1(zlmCond, R=bootstrapReplicates)
        end_time <- Sys.time()
        message("\n bootstrapping time ")
        print(end_time - start_time)
        gsea <- gseaAfterBoot(zlmCond, boots, sets_indices, CoefficientHypothesis("conditionKO"))
        z_stat_comb <- summary(gsea, testType='normal')
        sigModules <- z_stat_comb[combined_adj<gseaFDR]

When I run the code with 3 repetitions of bootstrapping (bootstrapReplicates <- 3), everything looks fine, but when I run it for real, with 60 bootstrapReplicates, I get a number (7 to be exact) of such warnings:

In, state, family) :
  fitted probabilities numerically 0 or 1 occurred

So, I have a few questions: 

- Can I trust the fit and consequently the enrichment?

- What are these warnings talking about?

- What, if anything, to do about them?

Thank you.

gsea mast • 171 views
ADD COMMENTlink written 7 months ago by santos229030

Can you provide the output from `sessionInfo()`?

ADD REPLYlink written 7 months ago by Andrew_McDavid190

Here it is, after running with 3 bootstrapReplicates:

> sessionInfo()
R version 3.4.4 (2018-03-15)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: OS X El Capitan 10.11.6

Matrix products: default
BLAS: /Library/Frameworks/R.framework/Versions/3.4/Resources/lib/libRblas.0.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.4/Resources/lib/libRlapack.dylib

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

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

other attached packages:
 [1] GSEABase_1.40.1            graph_1.56.0              
 [3] annotate_1.56.2            XML_3.98-1.16             
 [5] data.table_1.11.4          limma_3.34.9              
 [7]         AnnotationDbi_1.40.0      
 [9] SingleCellExperiment_1.0.0 MAST_1.4.1                
[11] SummarizedExperiment_1.8.1 DelayedArray_0.4.1        
[13] matrixStats_0.54.0         Biobase_2.38.0            
[15] GenomicRanges_1.30.3       GenomeInfoDb_1.14.0       
[17] IRanges_2.12.0             S4Vectors_0.16.0          
[19] BiocGenerics_0.24.0       

loaded via a namespace (and not attached):
 [1] tidyselect_0.2.4       purrr_0.2.5           
 [3] reshape2_1.4.3         lattice_0.20-35       
 [5] colorspace_1.3-2       blob_1.1.1            
 [7] rlang_0.2.2            pillar_1.3.0          
 [9] glue_1.3.0             DBI_1.0.0             
[11] bit64_0.9-7            bindrcpp_0.2.2        
[13] GenomeInfoDbData_1.0.0 plyr_1.8.4            
[15] bindr_0.1.1            stringr_1.3.1         
[17] zlibbioc_1.24.0        munsell_0.5.0         
[19] gtable_0.2.0           memoise_1.1.0         
[21] Rcpp_0.12.18           xtable_1.8-3          
[23] scales_1.0.0           XVector_0.18.0        
[25] abind_1.4-5            bit_1.1-14            
[27] ggplot2_3.0.0          digest_0.6.16         
[29] stringi_1.2.4          dplyr_0.7.6           
[31] grid_3.4.4             tools_3.4.4           
[33] bitops_1.0-6           magrittr_1.5          
[35] lazyeval_0.2.1         RCurl_1.95-4.11       
[37] tibble_1.4.2           RSQLite_2.1.1         
[39] crayon_1.3.4           pkgconfig_2.0.2       
[41] Matrix_1.2-14          assertthat_0.2.0      
[43] R6_2.2.2               compiler_3.4.4 
ADD REPLYlink written 7 months ago by santos229030
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 110 users visited in the last hour