Question: MSnbase addIdentificationData problem
0
gravatar for jd690764
27 days ago by
jd6907640
jd6907640 wrote:

I am trying to add mzIdent data to an MSnExp (which comes from an mgf file). addIdentificationData gives me an error:

Error in strsplit(ssv, sep) : non-character argument

The same error is produced if I provide z='path/to/mzID file' or read in the file with mzID('path/to/mzID file') first and just use the mzID object. I saw this was reported before, but I am using the latest version that should not have this problem.

Thank you for your help, Janos

> sessionInfo()
R version 3.6.0 (2019-04-26)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Mojave 10.14.5

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/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] mzID_1.22.0           RforProteomics_1.22.0 MSnbase_2.10.1        ProtGenerics_1.16.0   S4Vectors_0.22.0      mzR_2.18.0            Rcpp_1.0.1           
 [8] Biobase_2.44.0        BiocGenerics_0.30.0   forcats_0.4.0         stringr_1.4.0         purrr_0.3.2           readr_1.3.1           tidyr_0.8.3          
[15] tibble_2.1.3          ggplot2_3.2.0         tidyverse_1.2.1       dplyr_0.8.1           data.table_1.12.2    

loaded via a namespace (and not attached):
 [1] nlme_3.1-140          bitops_1.0-6          lubridate_1.7.4       doParallel_1.0.14     httr_1.4.0            tools_3.6.0           backports_1.1.4      
 [8] R6_2.4.0              affyio_1.54.0         lazyeval_0.2.2        colorspace_1.4-1      withr_2.1.2           tidyselect_0.2.5      compiler_3.6.0       
[15] preprocessCore_1.46.0 graph_1.62.0          cli_1.1.0             rvest_0.3.4           xml2_1.2.0            labeling_0.3          scales_1.0.0         
[22] affy_1.62.0           RBGL_1.60.0           digest_0.6.19         R.utils_2.9.0         pkgconfig_2.0.2       htmltools_0.3.6       limma_3.40.2         
[29] rlang_0.3.4           readxl_1.3.1          rstudioapi_0.10       impute_1.58.0         shiny_1.3.2           generics_0.0.2        jsonlite_1.6         
[36] BiocParallel_1.18.0   R.oo_1.22.0           RCurl_1.95-4.12       magrittr_1.5          MALDIquant_1.19.3     munsell_0.5.0         R.methodsS3_1.7.1    
[43] vsn_3.52.0            stringi_1.4.3         MASS_7.3-51.4         zlibbioc_1.30.0       biocViews_1.52.2      plyr_1.8.4            grid_3.6.0           
[50] promises_1.0.1        crayon_1.3.4          lattice_0.20-38       haven_2.1.0           hms_0.4.2             pillar_1.4.1          RUnit_0.4.32         
[57] codetools_0.2-16      XML_3.98-1.20         glue_1.3.1            pcaMethods_1.76.0     BiocManager_1.30.4    modelr_0.1.4          httpuv_1.5.1         
[64] foreach_1.4.4         cellranger_1.1.0      gtable_0.3.0          assertthat_0.2.1      mime_0.7              xtable_1.8-4          broom_0.5.2          
[71] later_0.8.0           ncdf4_1.16.1          iterators_1.0.10      IRanges_2.18.1  
software error msnbase • 39 views
ADD COMMENTlink modified 27 days ago by Laurent Gatto1.1k • written 27 days ago by jd6907640

Could you point me to the previous occurrence of this issue - it might help understanding what to underlying problem it. Also, could you share the data for debugging?

ADD REPLYlink written 27 days ago by Laurent Gatto1.1k

The previous report:

previous report

and the files that I am using:

mzid mgf

Thank you, Janos

ADD REPLYlink written 27 days ago by jd6907640
Answer: MSnbase addIdentificationData problem
0
gravatar for Laurent Gatto
27 days ago by
Laurent Gatto1.1k
United Kingdom
Laurent Gatto1.1k wrote:

The previous post to refer to is different than you issue. In your case, unfortunately, the addIdentificationData will not work as it expects to find information that it can't find when reading data from an mgf file. This code was written for the more complete mzML format in mind.

What you can however do it to read the identification data in as a data.frame with readMzIdData, filter it with filterIdentificationDataFrame (as is done in addIdentificationData). This should give you a spectrum.title column in the identification data.frame, that you will be able to match to the TITLE feature variable (fData) of your raw data object.

ADD COMMENTlink written 27 days ago by Laurent Gatto1.1k

Do you mean I should do an inner_join between the 2 tables and save the result in fData?

ADD REPLYlink written 27 days ago by jd6907640

Something along those lines yes.

ADD REPLYlink written 26 days ago by Laurent Gatto1.1k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 270 users visited in the last hour