Biostrings icon indicating copy to clipboard operation
Biostrings copied to clipboard

Unnecessary warning when using `readQualityScaledDNAStringSet`

Open LTLA opened this issue 1 year ago • 1 comments

library(Biostrings)
example(readQualityScaledDNAStringSet, echo=FALSE)
## Warning messages:
## 1: In XStringSet("DNA", x, start = start, end = end, width = width,  :
##   metadata columns on input DNAStringSet object were dropped
## 2: In XStringSet("DNA", x, start = start, end = end, width = width,  :
##   metadata columns on input DNAStringSet object were dropped

This stems from

https://github.com/Bioconductor/Biostrings/blob/35181af7b71c742ec60d36c617328c6e88aa89c4/R/QualityScaledXStringSet.R#L188

but the mcols are not wiped prior to

https://github.com/Bioconductor/Biostrings/blob/35181af7b71c742ec60d36c617328c6e88aa89c4/R/QualityScaledXStringSet.R#L193

which presumably leads to the warning above. Not breaking but it is annoying noise when using reading a FASTQ file.

Session info
R Under development (unstable) (2023-11-10 r85507)
Platform: x86_64-pc-linux-gnu
Running under: Ubuntu 20.04.6 LTS

Matrix products: default
BLAS:   /home/luna/Software/R/trunk/lib/libRblas.so 
LAPACK: /home/luna/Software/R/trunk/lib/libRlapack.so;  LAPACK version 3.11.0

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       

time zone: America/Los_Angeles
tzcode source: system (glibc)

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

other attached packages:
[1] Biostrings_2.71.1   GenomeInfoDb_1.39.2 XVector_0.43.0     
[4] IRanges_2.37.0      S4Vectors_0.41.2    BiocGenerics_0.49.1

loaded via a namespace (and not attached):
[1] zlibbioc_1.49.0         compiler_4.4.0          tools_4.4.0            
[4] GenomeInfoDbData_1.2.11 RCurl_1.98-1.13         crayon_1.5.2           
[7] bitops_1.0-7           

LTLA avatar Dec 27 '23 19:12 LTLA

Thanks for the callout -- this is fixed in https://github.com/Bioconductor/Biostrings/pull/110. Just going to do some testing to make sure nothing weird happens before merging.

ahl27 avatar Jun 06 '24 19:06 ahl27