bsseq - error with dmrFinder
0
0
Entering edit mode
varunorama • 0
@varunorama-13855
Last seen 4.9 years ago
University of Kentucky

Hello,

I am having some trouble with the dmrFinder function that is part of bsseq. The code that I running

>BS.cov = getCoverage(rrbs.smoothed)
>keepLoci.ex = which(rowSums(BS.cov[,rrbs$Type == "Control"] > 0) >= 10 &
                      rowSums(BS.cov[,rrbs$Type == "Regen"] > 0) >= 9 )

>rrbs.smoothed2 = rrbs.smoothed[keepLoci.ex,]

>rrbs.fitted.tstat = BSmooth.tstat(rrbs.smoothed2, 
                                  group1 = c("Day0-C","6Hr-C","12Hr-C","24Hr-C","48Hr-C",
                                             "72Hr-C","96Hr-C","120Hr-C","144Hr-C","168Hr-C"),
                                  group2 = c("6Hr-T","12Hr-T","24Hr-T","48Hr-T",
                                             "72Hr-T","96Hr-T","120Hr-T","144Hr-T","168Hr-T"),
                                  estimate.var = "group2",
                                  local.correct = TRUE,
                                  verbose=TRUE)

>dmrs0 = dmrFinder(rrbs.fitted.tstat)

receives an error:

Error in quantile.default(x, ...) : 
  missing values and NaN's not allowed if 'na.rm' is FALSE

I take it that the reason for this error is because there are missing values in the rrbs.fitted.tstat object.

Is there a way to disregard these missing values when considering the rrbs.fitted.tstat class? I've tried na.omit(rrbs.fitted.tstat) but that did not work.

> sessionInfo()
R version 3.4.1 (2017-06-30)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows >= 8 x64 (build 9200)

Matrix products: default

locale:
[1] LC_COLLATE=English_United States.1252  LC_CTYPE=English_United States.1252    LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C                           LC_TIME=English_United States.1252    

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

other attached packages:
 [1] bsseq_1.12.2               SummarizedExperiment_1.6.3 DelayedArray_0.2.7         matrixStats_0.52.2         Biobase_2.36.2            
 [6] GenomicRanges_1.28.4       GenomeInfoDb_1.12.2        IRanges_2.10.2             S4Vectors_0.14.3           BiocGenerics_0.22.0       
[11] BiocInstaller_1.26.0      

loaded via a namespace (and not attached):
 [1] Rcpp_0.12.12            XVector_0.16.0          zlibbioc_1.22.0         munsell_0.4.3           colorspace_1.3-2       
 [6] lattice_0.20-35         plyr_1.8.4              tools_3.4.1             grid_3.4.1              data.table_1.10.4      
[11] R.oo_1.21.0             gtools_3.5.0            permute_0.9-4           Matrix_1.2-10           GenomeInfoDbData_0.99.0
[16] R.utils_2.5.0           bitops_1.0-6            RCurl_1.95-4.8          limma_3.32.5            compiler_3.4.1         
[21] R.methodsS3_1.7.1       scales_0.5.0            locfit_1.5-9.1    

 

bsseq r package dmrfinder • 1.0k views
ADD COMMENT

Login before adding your answer.

Traffic: 628 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