stianlagstad / chimeraviz

chimeraviz is an R package that automates the creation of chimeric RNA visualizations.
36 stars 14 forks source link

Error during the execution of plot_fusion #96

Closed dplassard closed 1 year ago

dplassard commented 1 year ago

Hello,

Thank you for developing chimeraviz. I run plot_fusion on my fusions and it worked well. Now I am trying to rerun the same command (same conda environment, same input) but it doesn't work anymore. Here are the commands I executed:

star_fusion_res <- import_starfusion("star-fusion.fusion_predictions.abridged.tsv", "hg38")
fusion <- get_fusion_by_id(star_fusion_res, 12)
edb <- ensembldb::EnsDb("Homo_sapiens.GRCh38.103.sqlite")
bamfile <- "sample1.pos.bam"

pdf(file="fusion_plot_sample1.pdf")
plot_fusion(fusion = fusion, bamfile = bamfile, edb = edb, non_ucsc = FALSE, reduce_transcripts = TRUE)
dev.off()

But when the figure is generating, I get this error:

Fetching transcripts for gene partners..
..transcripts fetched.
Fusion is interchromosomal. Plot separate!
Selecting transcripts for ACTA2..
..found transcripts of type exonBoundary
Selecting transcripts for MITF..
..found transcripts of type exonBoundary
Error in .order_seqlevels(chrom_sizes[, "chrom"]) : 
  !anyNA(m32) is not TRUE

Do you have any idea why the command no longer works?

Thank you in advance, Best regards, Damien Plassard

Here is the output of sessionInfo():

sessionInfo()
R version 4.1.3 (2022-03-10)
Platform: x86_64-conda-linux-gnu (64-bit)
Running under: Debian GNU/Linux 9 (stretch)

Matrix products: default
BLAS/LAPACK: /shared/ngs/home/plassard/Conda/envs_conda_flash/chimeraviz/lib/libopenblasp-r0.3.21.so

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

other attached packages:
 [1] chimeraviz_1.20.0       data.table_1.14.6       ensembldb_2.18.1       
 [4] AnnotationFilter_1.18.0 GenomicFeatures_1.46.1  AnnotationDbi_1.56.2   
 [7] Biobase_2.54.0          Gviz_1.38.0             GenomicRanges_1.46.1   
[10] Biostrings_2.62.0       GenomeInfoDb_1.30.1     XVector_0.34.0         
[13] IRanges_2.28.0          S4Vectors_0.32.4        BiocGenerics_0.40.0    

loaded via a namespace (and not attached):
  [1] colorspace_2.0-3            rjson_0.2.21               
  [3] deldir_1.0-6                ellipsis_0.3.2             
  [5] biovizBase_1.42.0           htmlTable_2.4.1            
  [7] base64enc_0.1-3             dichromat_2.0-0.1          
  [9] rstudioapi_0.14             DT_0.26                    
 [11] bit64_4.0.5                 fansi_1.0.3                
 [13] xml2_1.3.3                  splines_4.1.3              
 [15] cachem_1.0.6                knitr_1.41                 
 [17] Formula_1.2-4               Rsamtools_2.10.0           
 [19] cluster_2.1.4               dbplyr_2.2.1               
 [21] png_0.1-8                   BiocManager_1.30.19        
 [23] compiler_4.1.3              httr_1.4.4                 
 [25] backports_1.4.1             assertthat_0.2.1           
 [27] Matrix_1.5-3                fastmap_1.1.0              
 [29] lazyeval_0.2.2              cli_3.5.0                  
 [31] org.Mm.eg.db_3.14.0         htmltools_0.5.4            
 [33] prettyunits_1.1.1           tools_4.1.3                
 [35] gtable_0.3.1                glue_1.6.2                 
 [37] GenomeInfoDbData_1.2.7      dplyr_1.0.10               
 [39] rappdirs_0.3.3              Rcpp_1.0.9                 
 [41] vctrs_0.5.1                 rtracklayer_1.54.0         
 [43] xfun_0.35                   stringr_1.5.0              
 [45] lifecycle_1.0.3             restfulr_0.0.15            
 [47] XML_3.99-0.13               org.Hs.eg.db_3.14.0        
 [49] zlibbioc_1.40.0             RCircos_1.2.2              
 [51] scales_1.2.1                BiocStyle_2.22.0           
 [53] BSgenome_1.62.0             VariantAnnotation_1.40.0   
 [55] hms_1.1.2                   MatrixGenerics_1.6.0       
 [57] ProtGenerics_1.26.0         parallel_4.1.3             
 [59] SummarizedExperiment_1.24.0 RColorBrewer_1.1-3         
 [61] yaml_2.3.6                  curl_4.3.3                 
 [63] memoise_2.0.1               gridExtra_2.3              
 [65] ggplot2_3.4.0               biomaRt_2.50.0             
 [67] rpart_4.1.19                latticeExtra_0.6-30        
 [69] stringi_1.7.8               RSQLite_2.2.19             
 [71] BiocIO_1.4.0                checkmate_2.1.0            
 [73] filelock_1.0.2              BiocParallel_1.28.3        
 [75] rlang_1.0.6                 pkgconfig_2.0.3            
 [77] matrixStats_0.63.0          bitops_1.0-7               
 [79] evaluate_0.19               lattice_0.20-45            
 [81] GenomicAlignments_1.30.0    htmlwidgets_1.6.0          
 [83] bit_4.0.5                   tidyselect_1.2.0           
 [85] plyr_1.8.8                  magrittr_2.0.3             
 [87] R6_2.5.1                    generics_0.1.3             
 [89] Hmisc_4.7-2                 DelayedArray_0.20.0        
 [91] DBI_1.1.3                   pillar_1.8.1               
 [93] foreign_0.8-84              survival_3.4-0             
 [95] KEGGREST_1.34.0             RCurl_1.98-1.9             
 [97] nnet_7.3-18                 tibble_3.1.8               
 [99] crayon_1.5.2                interp_1.1-3               
[101] utf8_1.2.2                  BiocFileCache_2.2.0        
[103] rmarkdown_2.19              jpeg_0.1-10                
[105] progress_1.2.2              blob_1.2.3                 
[107] digest_0.6.31               munsell_0.5.0 
stianlagstad commented 1 year ago

Hi @dplassard , thanks for posting! Would you be able to share your input files, either here publicly or by email? That would enable me to reproduce the problem locally and take a closer look.

dplassard commented 1 year ago

Hi @stianlagstad, thank you for your response! You will find enclosed the STAR-Fusion output file. Concerning the .sqlite file, I built it using annotation file from Ensembl v.103 (but I tested other versions and I have the same problem). The error is the same if I use the BAM file or not.

plot_fusion(fusion = fusion, edb = edb, non_ucsc = FALSE, reduce_transcripts = TRUE)

star-fusion.fusion_predictions.abridged.txt

Best regards, Damien

stianlagstad commented 1 year ago

Hi @dplassard , thanks for getting back to me. I've reproduced the issue that you got. I found this related thread about it: https://github.com/Bioconductor/GenomeInfoDb/issues/82. The recommendation there is to make sure that you're on a version of the package GenomeInfoDb>=1.34.8 (if on BioC 3.16), or GenomeInfoDb>=1.35.14 (if on BioC 3.17). Please try that, and post here to update on whether or not that worked. I'm pretty certain that it'll work, so I'll close this issue, but don't hesitate to ask more if there's anything. Thanks!

dplassard commented 1 year ago

Hi @stianlagstad, it works now, thank you very much!

stianlagstad commented 1 year ago

Great to hear @dplassard , thanks for getting back to me to confirm that.