hansenlab / bsseq

Devel repository for bsseq
35 stars 25 forks source link

Can not extract smoothed methylation data #78

Open HeyLifeHD opened 5 years ago

HeyLifeHD commented 5 years ago

I recently updated to R3.5 and continued using my "old" bsseq objects created under R3.4. Upon updating the objects it is no problem for me to handle the bsseq objects as usual, however when I try to extract the smoothed methylation matrix I get following error:

> getMeth(AM.BS.fit, type="smooth")
Error in register_delayed_op(q, "plogis", Rargs = list(location = location,  :
  could not find function "register_delayed_op"
> traceback()
3: getBSseq(BSseq, "trans", withDimnames)(coef)
2: getBSseq(BSseq, "trans", withDimnames)(coef)
1: getMeth(AM.BS.fit, type = "smooth")
> sessionInfo()

R version 3.5.1 (2018-07-02)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 18.04.1 LTS

Matrix products: default
BLAS: /usr/lib/x86_64-linux-gnu/blas/libblas.so.3.7.1
LAPACK: /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3.7.1

locale:
 [1] LC_CTYPE=C.UTF-8           LC_NUMERIC=C
 [3] LC_TIME=fr_FR.UTF-8        LC_COLLATE=C.UTF-8
 [5] LC_MONETARY=fr_FR.UTF-8    LC_MESSAGES=C.UTF-8
 [7] LC_PAPER=fr_FR.UTF-8       LC_NAME=C
 [9] LC_ADDRESS=C               LC_TELEPHONE=C
[11] LC_MEASUREMENT=fr_FR.UTF-8 LC_IDENTIFICATION=C

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

other attached packages:
 [1] bsseq_1.18.0                SummarizedExperiment_1.12.0
 [3] DelayedArray_0.9.0          BiocParallel_1.16.2
 [5] matrixStats_0.54.0          Biobase_2.42.0
 [7] GenomicRanges_1.34.0        GenomeInfoDb_1.18.1
 [9] IRanges_2.16.0              S4Vectors_0.20.1
[11] BiocGenerics_0.28.0

loaded via a namespace (and not attached):
 [1] Rcpp_1.0.0               compiler_3.5.1           XVector_0.22.0
 [4] R.methodsS3_1.7.1        bitops_1.0-6             R.utils_2.7.0
 [7] DelayedMatrixStats_1.4.0 tools_3.5.1              zlibbioc_1.28.0
[10] rhdf5_2.26.0             lattice_0.20-38          BSgenome_1.50.0
[13] Matrix_1.2-15            GenomeInfoDbData_1.2.0   rtracklayer_1.42.1
[16] Biostrings_2.50.1        gtools_3.8.1             locfit_1.5-9.1
[19] grid_3.5.1               data.table_1.11.8        HDF5Array_1.10.1
[22] XML_3.98-1.16            limma_3.38.3             Rhdf5lib_1.4.2
[25] scales_1.0.0             Rsamtools_1.34.0         GenomicAlignments_1.18.0
[28] beachmat_1.4.0           permute_0.9-4            colorspace_1.3-2
[31] RCurl_1.95-4.11          munsell_0.5.0            R.oo_1.22.0

Thanks for your support.

Joschka

PeteHaitch commented 5 years ago

Hi Joschka, Are you able to share the object? This will help me with debugging. Thanks, Pete

PeteHaitch commented 5 years ago

Please also post the output of BiocManager::valid() (you may instead need to use BiocInstaller::biocValid() for the older version of R).

HeyLifeHD commented 5 years ago

Sorry for the late response. However, I still have this problem with R3.6. This is the ouput for valid() BiocManager::valid()

R version 3.6.1 (2019-07-05) Platform: x86_64-pc-linux-gnu (64-bit) Running under: Ubuntu 18.04.2 LTS

Matrix products: default BLAS: /usr/lib/x86_64-linux-gnu/openblas/libblas.so.3 LAPACK: /usr/lib/x86_64-linux-gnu/libopenblasp-r0.2.20.so

locale: [1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C
[3] LC_TIME=de_DE.UTF-8 LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=de_DE.UTF-8 LC_MESSAGES=en_US.UTF-8
[7] LC_PAPER=de_DE.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=de_DE.UTF-8 LC_IDENTIFICATION=C

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

other attached packages: [1] bsseq_1.20.0 SummarizedExperiment_1.14.0 [3] DelayedArray_0.10.0 BiocParallel_1.18.0
[5] matrixStats_0.54.0 Biobase_2.44.0
[7] GenomicRanges_1.36.0 GenomeInfoDb_1.20.0
[9] IRanges_2.18.1 S4Vectors_0.22.0
[11] BiocGenerics_0.30.0

loaded via a namespace (and not attached): [1] Rcpp_1.0.2 compiler_3.6.1 BiocManager_1.30.4
[4] XVector_0.24.0 R.methodsS3_1.7.1 R.utils_2.9.0
[7] bitops_1.0-6 tools_3.6.1 DelayedMatrixStats_1.6.0 [10] zlibbioc_1.30.0 rhdf5_2.28.0 lattice_0.20-38
[13] BSgenome_1.52.0 Matrix_1.2-17 GenomeInfoDbData_1.2.1
[16] rtracklayer_1.44.2 Biostrings_2.52.0 gtools_3.8.1
[19] locfit_1.5-9.1 grid_3.6.1 data.table_1.12.2
[22] HDF5Array_1.12.1 XML_3.98-1.20 limma_3.40.2
[25] Rhdf5lib_1.6.0 scales_1.0.0 Rsamtools_2.0.0
[28] GenomicAlignments_1.20.1 permute_0.9-5 colorspace_1.4-1
[31] RCurl_1.95-4.12 munsell_0.5.0 R.oo_1.22.0

Bioconductor version '3.9'

create a valid installation with

BiocManager::install(c( "BiocParallel", "biomaRt", "callr", "ChIPpeakAnno", "clipr", "cowplot", "curl", "doParallel", "edgeR", "fields", "foreach", "ggforce", "ggplot2", "ggplotify", "ggpubr", "ggsignif", "Gviz", "HDF5Array", "httr", "iterators", "knitr", "limma", "markdown", "modelr", "openssl", "pkgbuild", "processx", "RcppArmadillo", "rmarkdown", "RSQLite", "SummarizedExperiment", "survminer", "TCGAbiolinks", "testthat", "tinytex", "xfun", "xml2" ), update = TRUE, ask = FALSE)

more details: BiocManager::valid()$too_new, BiocManager::valid()$out_of_date

Warning message: 37 packages out-of-date; 0 packages too new

I am sorry but sharing of the object will be difficult.... Let me know if you really need it for the full debugging.

Thanks

jagi25 commented 5 years ago

Hi everybody,

i am still facing the same issues as Joschka. I generated a BSseq object under the R version 3.4.3 (bsseq 1.14.0) and recently updated R to 3.6.0 (bsseq version 1.20.0). I updated the object with: object <- updateObject(object, verbose=T) but i get the same error when i try to extract methylation levels from the smoothed BSseq object:

M <- getMeth(meth.smooth, type="smooth") _Error in register_delayed_op(q, "plogis", Rargs = list(location = location, : could not find function "register_delayedop"

However, it does not appear, when i do: M <- getMeth(meth.smooth, type="raw")

So my question is if this bug still appears in the new bsseq version (1.21.1) or is it already fixed? Unfortunately i can not share the object with you but if you have any question regarding the procedure, please contact me.

sessionInfo()

R version 3.6.0 (2019-04-26) Platform: x86_64-pc-linux-gnu (64-bit) Running under: CentOS Linux 7 (Core)

Matrix products: default BLAS: /sw/apps/R/x86_64/3.6.0/rackham/lib64/R/lib/libRblas.so LAPACK: /sw/apps/R/x86_64/3.6.0/rackham/lib64/R/lib/libRlapack.so

Random number generation: RNG: Mersenne-Twister Normal: Inversion Sample: Rounding

locale: [1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C [3] LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8 [5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 [7] LC_PAPER=en_US.UTF-8 LC_NAME=C [9] LC_ADDRESS=C LC_TELEPHONE=C [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

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

other attached packages: [1] HDF5Array_1.12.1 rhdf5_2.28.0 [3] bsseq_1.20.0 SummarizedExperiment_1.14.0 [5] DelayedArray_0.10.0 BiocParallel_1.18.0 [7] matrixStats_0.54.0 Biobase_2.44.0 [9] GenomicRanges_1.36.0 GenomeInfoDb_1.20.0 [11] IRanges_2.18.0 S4Vectors_0.22.0 [13] BiocGenerics_0.30.0

loaded via a namespace (and not attached): [1] Rcpp_1.0.1 compiler_3.6.0 XVector_0.24.0 [4] R.methodsS3_1.7.1 bitops_1.0-6 R.utils_2.8.0 [7] tools_3.6.0 DelayedMatrixStats_1.6.0 zlibbioc_1.30.0 [10] lattice_0.20-38 BSgenome_1.52.0 Matrix_1.2-17 [13] GenomeInfoDbData_1.2.1 rtracklayer_1.44.0 Biostrings_2.52.0 [16] gtools_3.8.1 locfit_1.5-9.1 grid_3.6.0 [19] data.table_1.12.2 XML_3.98-1.19 limma_3.40.0 [22] Rhdf5lib_1.6.0 scales_1.0.0 Rsamtools_2.0.0 [25] GenomicAlignments_1.20.0 beachmat_2.0.0 permute_0.9-5 [28] colorspace_1.4-1 RCurl_1.95-4.12 munsell_0.5.0 [31] R.oo_1.22.0

Cheers and thanks for your help Jannik

kasperdanielhansen commented 5 years ago

Run the code and then, after the code has run, run the following and report the output

  library(BiocManager)
  BiocManager::valid()

On Thu, Sep 12, 2019 at 8:35 AM jagi25 notifications@github.com wrote:

Hi everybody,

i am still facing the same issues as Joschka. I generated a BSseq object under the R version 3.4.3 (bsseq 1.14.0) and recently updated R to 3.6.0 (bsseq version 1.20.0). I updated the object with: object <- updateObject(object, verbose=T) but i get the same error when i try to extract methylation levels from the smoothed BSseq object:

M <- getMeth(meth.smooth, type="smooth")

Error in register_delayed_op(q, "plogis", Rargs = list(location = location, : could not find function "register_delayed_op"

However, it does not appear, when i do: M <- getMeth(meth.smooth, type="raw")

So my question is if this bug still appears in the new bsseq version (1.21.1) or is it already fixed? Unfortunately i can not share the object with you but if you have any question regarding the procedure, please contact me.

sessionInfo()

R version 3.6.0 (2019-04-26) Platform: x86_64-pc-linux-gnu (64-bit) Running under: CentOS Linux 7 (Core)

Matrix products: default BLAS: /sw/apps/R/x86_64/3.6.0/rackham/lib64/R/lib/libRblas.so LAPACK: /sw/apps/R/x86_64/3.6.0/rackham/lib64/R/lib/libRlapack.so

Random number generation: RNG: Mersenne-Twister Normal: Inversion Sample: Rounding

locale: [1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C [3] LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8 [5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 [7] LC_PAPER=en_US.UTF-8 LC_NAME=C [9] LC_ADDRESS=C LC_TELEPHONE=C [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

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

other attached packages: [1] HDF5Array_1.12.1 rhdf5_2.28.0 [3] bsseq_1.20.0 SummarizedExperiment_1.14.0 [5] DelayedArray_0.10.0 BiocParallel_1.18.0 [7] matrixStats_0.54.0 Biobase_2.44.0 [9] GenomicRanges_1.36.0 GenomeInfoDb_1.20.0 [11] IRanges_2.18.0 S4Vectors_0.22.0 [13] BiocGenerics_0.30.0

loaded via a namespace (and not attached): [1] Rcpp_1.0.1 compiler_3.6.0 XVector_0.24.0 [4] R.methodsS3_1.7.1 bitops_1.0-6 R.utils_2.8.0 [7] tools_3.6.0 DelayedMatrixStats_1.6.0 zlibbioc_1.30.0 [10] lattice_0.20-38 BSgenome_1.52.0 Matrix_1.2-17 [13] GenomeInfoDbData_1.2.1 rtracklayer_1.44.0 Biostrings_2.52.0 [16] gtools_3.8.1 locfit_1.5-9.1 grid_3.6.0 [19] data.table_1.12.2 XML_3.98-1.19 limma_3.40.0 [22] Rhdf5lib_1.6.0 scales_1.0.0 Rsamtools_2.0.0 [25] GenomicAlignments_1.20.0 beachmat_2.0.0 permute_0.9-5 [28] colorspace_1.4-1 RCurl_1.95-4.12 munsell_0.5.0 [31] R.oo_1.22.0

Cheers and thanks for your help Jannik

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/hansenlab/bsseq/issues/78?email_source=notifications&email_token=ABF2DH4GDKQ67HPTSGJ4ZU3QJIZSZA5CNFSM4GJA4ZB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD6RW5MA#issuecomment-530804400, or mute the thread https://github.com/notifications/unsubscribe-auth/ABF2DH6CYGAQC3UBWVQYCVLQJIZSZANCNFSM4GJA4ZBQ .

-- Best, Kasper

jagi25 commented 5 years ago

Thanks for the quick response! Unfortunately, i am working on the highly secure server which does not allow access to internet, so i am not able to run your suggested code! Is there another way to get the information you need?

Cheers Jannik

kasperdanielhansen commented 5 years ago

This code checks that all your packages are current and are from the same branch of Bioconductor. I can't go through and check this manually, but spot checking reveals that at least Rhdf5lib and HDF5Array has newer versions in Bioc stable. I don't know if updating would help, but it really builds confidence to know that you're current.

On Thu, Sep 12, 2019 at 8:56 AM jagi25 notifications@github.com wrote:

Thanks for the quick response! Unfortunately, i am working on the highly secure server which does not allow access to internet, so i am not able to run your suggested code! Is there another way to get the information you need?

Cheers Jannik

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/hansenlab/bsseq/issues/78?email_source=notifications&email_token=ABF2DH7PJH623BKB327IEQTQJI4AZA5CNFSM4GJA4ZB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD6RY4RI#issuecomment-530812485, or mute the thread https://github.com/notifications/unsubscribe-auth/ABF2DH2PHII5B75FZCPVQHTQJI4AZANCNFSM4GJA4ZBQ .

-- Best, Kasper

jagi25 commented 5 years ago

I will try to do that and I will come back to you after having tried the updating! Thanks for your help!!