Error with PDtoMSstatsFormat function

135 views
Skip to first unread message

Sam Siljee

unread,
Nov 22, 2022, 8:53:34 PM11/22/22
to MSstats
Hi all,

I'm looking at using MSstats for my PhD project, and am having some trouble importing my pilot proteomics data from Proteome Discoverer (2.4).
When I run the `PDtoMSstatsFormat` function, I get the output:

Error in `[.data.table`(pd_input, , pd_cols, with = FALSE) :
column(s) not found: ProteinGroupAccessions, PrecursorArea

My input data is the PSMs table exported as a tsv file, I suspect there's some thing I'm doing wrong in PD to end up without protein group accessions and precursor area columns.
Alternatively, it could be the fact that I'm comparing one biological replicate run with two different acquisition methods. (label-free quantification).

Sorry if I didn't word the question clearly, I'm still learning!

Many thanks!
Sam

Priyam Jani

unread,
Dec 7, 2022, 3:33:18 PM12/7/22
to MSstats
Hi Sam, I think you have to manually rename those two column headers before importing to MSStats. There is another thread here where it was discussed.

Sam Siljee

unread,
Dec 19, 2022, 3:08:03 PM12/19/22
to MSstats
Thank you for that!
I've solved that problem using `mutate` to add a column "ProteinGroupAccessions" from the original column "Master.Protein.Accessions", however I could not find a corresponding column for PrecursorArea.
I've subsequently solved this by running a search in PD with all raw files and LFQ (as opposed to running each separately), which gave the column "Precursor.Abundance".
Now however I run into the problem where I get a long list of "returning -InfWarning: no non-missing arguments to max;" errors, and then

"INFO  [2022-12-20 09:03:57] ** Multiple measurements in a feature and a run are summarized by summaryforMultipleRows: max
INFO  [2022-12-20 09:03:57] ** Features with one or two measurements across runs are removed.
INFO  [2022-12-20 09:03:57] ** Run annotation merged with quantification data.
INFO  [2022-12-20 09:03:57] ** Features with one or two measurements across runs are removed.
INFO  [2022-12-20 09:03:57] ** Fractionation handled.
Error in setnames(x, value) :
  Can't assign 4 names to a 0 column data.table"

Is there someone who's also had this problem?

Thanks!
Sam

Sam Siljee

unread,
Dec 20, 2022, 8:45:28 PM12/20/22
to MSstats
I have a theory that it;s due to the fact I've only got two runs in my data set, and that they get filtered out because there will alway be less than three observations.

Sam

Mateusz Staniak

unread,
Dec 21, 2022, 5:09:50 AM12/21/22
to MSstats
Hi Sam,

I'll look for other possible causes and update the converter to handle alternative column names, but if having only two runs is the problem, you can turn off that filtering step using the "removeFewMeasurements" parameter.


Kind regards
Mateusz

Sam Siljee

unread,
Dec 21, 2022, 2:49:09 PM12/21/22
to MSstats
Thank you Mateusz, I really appreciate your help!

I've tried adding the argument "removeFewMeasurements = FALSE" how I get the same error.
I've also tried with another trial dataset from five runs, with the same results.
I've attached some of the trial dataset.

SessionInfo
R version 4.2.1 (2022-06-23 ucrt)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 19044)

Matrix products: default

locale:
[1] LC_COLLATE=English_New Zealand.utf8  LC_CTYPE=English_New Zealand.utf8    LC_MONETARY=English_New Zealand.utf8
[4] LC_NUMERIC=C                         LC_TIME=English_New Zealand.utf8    

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

other attached packages:
 [1] forcats_0.5.2   stringr_1.5.0   dplyr_1.0.10    purrr_0.3.5     readr_2.1.3     tidyr_1.2.1    
 [7] tibble_3.1.8    ggplot2_3.4.0   tidyverse_1.3.2 MSstats_4.4.1

Best regards,
Sam
col_annotation.csv
sam_test_data.csv

Sam Siljee

unread,
Jan 31, 2023, 9:09:58 PM1/31/23
to MSstats
As an update to this, I've updated a bunch of the other packages, and it's now working as it should.
Perhaps I was having problems with the dependencies? Either way, I'm happy it's fixed!

Sam
Reply all
Reply to author
Forward
0 new messages