MCorentin / vargen

VarGen is an R package designed to get a list of variants related to a disease. It just need an OMIM morbid ID as input and optionally a list of tissues / gwas traits of interest to complete the results. You can also use your own customised list of genes. VarGen is capable of annotating the variants to help you identify the most impactful ones.
MIT License
14 stars 3 forks source link

GWAS traits - ERROR- unable to find an inherited method for function ‘seqinfo’ for signature ‘"list"’ #10

Closed matteozoia4 closed 1 year ago

matteozoia4 commented 1 year ago

Dear all,

During the GWAS Traits step I am receiving this error and so far I didn't managed to understand the source of it.

In the vargen_data folder I correctly have the .tsv GWAS catalog : _gwas_catalog_v1.0-associations_e108r2022-11-01.tsv

gwas_cat <- create_gwas("./vargen_data/") Error in (function (classes, fdef, mtable) : unable to find an inherited method for function ‘seqinfo’ for signature ‘"list"’

Many thanks for the help!

R version 4.2.1 (2022-06-23)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Monterey 12.0.1

Matrix products: default
LAPACK: /Library/Frameworks/R.framework/Versions/4.2/Resources/lib/libRlapack.dylib

locale:
[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] stats4    stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] vargen_0.2.1                devtools_2.4.5              usethis_2.1.6               data.table_1.14.4          
 [5] myvariant_1.26.0            VariantAnnotation_1.42.1    Rsamtools_2.12.0            Biostrings_2.64.1          
 [9] XVector_0.36.0              SummarizedExperiment_1.26.1 Biobase_2.56.0              MatrixGenerics_1.8.1       
[13] matrixStats_0.62.0          R.utils_2.12.1              R.oo_1.25.0                 R.methodsS3_1.8.2          
[17] rtracklayer_1.56.1          ggplot2_3.4.0               splitstackshape_1.4.8       stringr_1.4.1              
[21] httr_1.4.4                  jsonlite_1.8.3              gwascat_2.28.1              GenomicRanges_1.48.0       
[25] GenomeInfoDb_1.32.4         IRanges_2.30.1              S4Vectors_0.34.0            BiocGenerics_0.42.0        
[29] gtools_3.9.3                biomaRt_2.52.0             

loaded via a namespace (and not attached):
  [1] backports_1.4.1          Hmisc_4.7-1              BiocFileCache_2.4.0      plyr_1.8.7               splines_4.2.1           
  [6] BiocParallel_1.30.4      digest_0.6.30            htmltools_0.5.3          fansi_1.0.3              magrittr_2.0.3          
 [11] checkmate_2.1.0          memoise_2.0.1            BSgenome_1.64.0          cluster_2.1.4            tzdb_0.3.0              
 [16] remotes_2.4.2            readr_2.1.3              prettyunits_1.1.1        jpeg_0.1-9               colorspace_2.0-3        
 [21] blob_1.2.3               rappdirs_0.3.3           xfun_0.34                dplyr_1.0.10             callr_3.7.3             
 [26] crayon_1.5.2             RCurl_1.98-1.9           survival_3.4-0           glue_1.6.2               gtable_0.3.1            
 [31] zlibbioc_1.42.0          DelayedArray_0.22.0      pkgbuild_1.3.1           scales_1.2.1             DBI_1.1.3               
 [36] miniUI_0.1.1.1           Rcpp_1.0.9               xtable_1.8-4             progress_1.2.2           htmlTable_2.4.1         
 [41] foreign_0.8-83           bit_4.0.4                Formula_1.2-4            profvis_0.3.7            htmlwidgets_1.5.4       
 [46] RColorBrewer_1.1-3       ellipsis_0.3.2           urlchecker_1.0.1         pkgconfig_2.0.3          XML_3.99-0.12           
 [51] nnet_7.3-18              dbplyr_2.2.1             deldir_1.0-6             utf8_1.2.2               tidyselect_1.2.0        
 [56] rlang_1.0.6              later_1.3.0              AnnotationDbi_1.58.0     munsell_0.5.0            tools_4.2.1             
 [61] cachem_1.0.6             cli_3.4.1                generics_0.1.3           RSQLite_2.2.18           fastmap_1.1.0           
 [66] yaml_2.3.6               processx_3.8.0           knitr_1.40               bit64_4.0.5              fs_1.5.2                
 [71] purrr_0.3.5              KEGGREST_1.36.3          mime_0.12                xml2_1.3.3               compiler_4.2.1          
 [76] rstudioapi_0.14          filelock_1.0.2           curl_4.3.3               png_0.1-7                tibble_3.1.8            
 [81] stringi_1.7.8            ps_1.7.2                 GenomicFeatures_1.48.4   lattice_0.20-45          Matrix_1.5-1            
 [86] vctrs_0.5.0              pillar_1.8.1             lifecycle_1.0.3          BiocManager_1.30.19      snpStats_1.46.0         
 [91] bitops_1.0-7             httpuv_1.6.6             R6_2.5.1                 BiocIO_1.6.0             latticeExtra_0.6-30     
 [96] promises_1.2.0.1         gridExtra_2.3            sessioninfo_1.2.2        codetools_0.2-18         assertthat_0.2.1        
[101] pkgload_1.3.1            rjson_0.2.21             withr_2.5.0              GenomicAlignments_1.32.1 GenomeInfoDbData_1.2.8  
[106] parallel_4.2.1           hms_1.1.2                grid_4.2.1               rpart_4.1.19             shiny_1.7.3
MCorentin commented 1 year ago

Dear matteozoia4,

Thanks for raising this issue, I managed to reproduce it and solved it in the latest commit (e1606748160da64c4245def1ef79247ad5785242).

Please pull the latest commit from vargen, reinstall the package and let me know if it is working on your side.

matteozoia4 commented 1 year ago

Many thanks for your help, now it is working fine!

I was just wondering if it is normal that to load the GTEx table it is taking so long : "Loading GTEx lookup table... Please be patient"

I entered 416 OMIN ID though, could be that R struggle to load the table for a memory issue?

Many thanks!

MZ

MCorentin commented 1 year ago

You are welcome, glad it is working.

Yes, the GTEx lookup table is quite large and takes a long time to load. This is not related to the amount of OMIM IDs you are querying.

I am planning to implement the lookup table as a local database (instead of a file), and only query the variant IDs of interest, instead of loading the whole table, it should make the process much faster.