Proteomics and metabolomics
This page covers mass spectrometry data from proteomics and metabolomics. Notes read raw files in open formats, quantify peptides, proteins or metabolite features, and compare groups.
Prompts to try
From peptides to proteins. Send:
Read the CPTAC peptide table from MsDataHub into a QFeatures object, with the condition, 6A or 6B, for each sample.Then:
Replace zeros with NA, remove peptides missing in 4 or more of the 6 samples, then remove reverse hits, contaminants and peptides with a PEP above 0.05.Inspect the spectra of a TMT11 MS3 run:
Load the MS3TMT11 mzML file from MsDataHub with Spectra.Detect chromatographic peaks in LC-MS metabolomics data. Send:
Load the faahKO CDF files from the faahKO package into an MsExperiment, with genotype labels.Then:
How does centWave decide what counts as a peak?Annotate compounds from their MS2 spectra:
Load the PestMix1 DDA file from MsDataHub with Spectra and keep the MS2 spectra.
What a note can do
The methods follow the books R for Mass Spectrometry and Metabonaut.
Proteomics
- Raw spectra. Spectra reads and plots mzML files.
- Identifications. PSMatch reads search results and uses decoy hits to judge them.
- Quantification. QFeatures keeps PSMs, peptides and proteins linked while it aggregates them, including TMT reporter ions.
- Missing values. Notes explore missingness and compare imputation methods.
- Compare groups. limma and msqrob2 find proteins that differ, shown in volcano plots.
- More. scp handles single-cell proteomics and pRoloc subcellular localisation.
Metabolomics
- Raw data. Notes read LC-MS files into an MsExperiment and check them with chromatograms.
- Preprocessing. xcms finds peaks (centWave), lines up retention times and matches peaks across samples.
- Annotation. MetaboAnnotation and CompoundDb match masses and fragment spectra to known compounds, for example from MassBank. MetaboCoreUtils works out masses and adducts.
- Compare groups. The features are collected into a table and tested between groups.
Data can come from MsDataHub, msdata, faahKO, scpdata and pRolocdata, or from your files. Notes read open formats such as mzML and CDF in R; convert vendor formats to mzML before you upload them.
Example notes

- Reporter ions in a TMT11 MS3 run: where the reporter ions appear in the spectra.
- Peptide identifications and the target-decoy approach: judging search results with decoys.
- From PSMs to proteins with QFeatures: aggregation from PSM to peptide to protein.
- Spike-in proteins: from peptides to a volcano plot: a full pipeline, checked against proteins known to be added.
- Missing values in proteomics: to impute or not: how much the choice of imputation method matters.
- First look at untargeted LC-MS data: raw files and chromatograms before any processing.
- Chromatographic peak detection with centWave: peak finding tried on one ion first.
- MS2 spectral matching against MassBank: naming compounds by comparing fragment spectra.