tgirke / systemPipeRdata

NGS workflow templates and sample data
9 stars 8 forks source link

plotfeatureCoverage sort x-axis wrongly #11

Closed yeroslaviz closed 3 years ago

yeroslaviz commented 3 years ago

Running teh commands:

fcov <- featureCoverage(bfl = BamFileList(outpaths[1:4]), grl = grl[1:12], 
    resizereads = NULL, readlengthrange = NULL, Nbins = NULL, 
    method = mean, fixedmatrix = TRUE, resizefeatures = TRUE, 
    upstream = 20, downstream = 20, outfile = "results/featureCoverage.xls", 
    overwrite = TRUE)
plotfeatureCoverage(covMA = fcov, method = mean, scales = "fixed", 
    extendylim = 2, scale_count_val = 10^6)

I'm trying to create a coverage plot from your worflow, but the command sort the x-axis wrongly (see below).

Can you please help me sort the positions in the correct order?

thanks

Screen Shot 2021-05-10 at 3 18 09 PM
> sessionInfo()
R version 4.0.5 (2021-03-31)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Catalina 10.15.7

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.0/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    parallel  stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] rtracklayer_1.50.0          GenomicFeatures_1.42.3      AnnotationDbi_1.52.0        systemPipeRdata_1.18.2      systemPipeR_1.24.6         
 [6] ShortRead_1.48.0            GenomicAlignments_1.26.0    SummarizedExperiment_1.20.0 Biobase_2.50.0              MatrixGenerics_1.2.1       
[11] matrixStats_0.58.0          BiocParallel_1.24.1         Rsamtools_2.6.0             Biostrings_2.58.0           XVector_0.30.0             
[16] GenomicRanges_1.42.0        GenomeInfoDb_1.26.7         IRanges_2.24.1              S4Vectors_0.28.1            BiocGenerics_0.36.1        

loaded via a namespace (and not attached):
  [1] colorspace_2.0-1         rjson_0.2.20             hwriter_1.3.2            ellipsis_0.3.2           rstudioapi_0.13          farver_2.1.0            
  [7] remotes_2.3.0            bit64_4.0.5              fansi_0.4.2              xml2_1.3.2               splines_4.0.5            cachem_1.0.4            
 [13] knitr_1.33               jsonlite_1.7.2           annotate_1.68.0          GO.db_3.12.1             dbplyr_2.1.1             png_0.1-8               
 [19] pheatmap_1.0.12          graph_1.68.0             BiocManager_1.30.12      compiler_4.0.5           httr_1.4.2               GOstats_2.56.0          
 [25] backports_1.2.1          assertthat_0.2.1         Matrix_1.3-3             fastmap_1.1.0            cli_2.5.0                limma_3.46.0            
 [31] htmltools_0.5.1.1        prettyunits_1.1.1        tools_4.0.5              gtable_0.3.0             glue_1.4.2               GenomeInfoDbData_1.2.4  
 [37] Category_2.56.0          dplyr_1.0.6              rsvg_2.1.2               batchtools_0.9.15        rappdirs_0.3.3           V8_3.4.2                
 [43] Rcpp_1.0.6               vctrs_0.3.8              debugme_1.1.0            xfun_0.22                stringr_1.4.0            lifecycle_1.0.0         
 [49] XML_3.99-0.6             edgeR_3.32.1             zlibbioc_1.36.0          scales_1.1.1             BiocStyle_2.18.1         BSgenome_1.58.0         
 [55] VariantAnnotation_1.36.0 hms_1.0.0                RBGL_1.66.0              RColorBrewer_1.1-2       yaml_2.2.1               curl_4.3.1              
 [61] memoise_2.0.0            ggplot2_3.3.3            biomaRt_2.46.3           latticeExtra_0.6-30      stringi_1.5.3            RSQLite_2.2.7           
 [67] genefilter_1.72.1        checkmate_2.0.0          DOT_0.1                  rlang_0.4.11             pkgconfig_2.0.3          bitops_1.0-7            
 [73] evaluate_0.14.1          lattice_0.20-44          purrr_0.3.4              labeling_0.4.2           bit_4.0.4                tidyselect_1.1.1        
 [79] GSEABase_1.52.1          AnnotationForge_1.32.0   magrittr_2.0.1           R6_2.5.0                 generics_0.1.0           base64url_1.4           
 [85] DelayedArray_0.16.3      DBI_1.1.1                pillar_1.6.0             withr_2.4.2              survival_3.2-11          RCurl_1.98-1.3          
 [91] tibble_3.1.1             crayon_1.4.1             utf8_1.2.1               BiocFileCache_1.14.0     rmarkdown_2.8            jpeg_0.1-8.1            
 [97] progress_1.2.2           locfit_1.5-9.4           grid_4.0.5               data.table_1.14.0        blob_1.2.1               Rgraphviz_2.34.0        
[103] digest_0.6.27            xtable_1.8-6             brew_1.0-6               openssl_1.4.4            munsell_0.5.0            askpass_1.1       
dcassol commented 3 years ago

Hello @yeroslaviz, Thank you for bringing this to my attention. I fixed the x-axis sorting. However, since we are close to the new release, I recommend you to install the new version as follows:

devtools::install_github("tgirke/systemPipeR", ref="RELEASE_3_12")

Thank you! All the best, Daniela

dcassol commented 3 years ago

Hello @yeroslaviz I'm going to close this for now, as we haven't heard back from you in a while. Feel free to re-open if you have any additional questions. Cheers, Daniela