synapter (version 1.14.2)

makeMaster: Merges final peptide files

Description

This function combines a list of peptide final peptide files into one single master file that is obtained by merging the unique peptides from the filtered original peptide files.

Usage

makeMaster(pepfiles, fdr = 0.01, method = c("BH", "Bonferroni", "qval"),
  span = 0.05, verbose = TRUE)

Arguments

pepfiles
A list of peptide final peptide file names to be merged.
fdr
A numeric indicating the preptide false discovery rate limit.
method
A character indicating the p-value adjustment to be used. One of BH (default), Bonferroni or qval.
span
A numeric with the loess span parameter value to be used for retention time modelling.
verbose
A logical indicating information should be printed out.

Value

  • An instance of class "MasterPeptides".

Details

The merging process is as follows:
  1. Each individual peptide final peptide file is filtered to retain (i) non-duplicated unique tryptic peptides, (ii) peptides with a false discovery rate <=fdrand (iii) proteins with a false positive rate <=fpr.
  2. The filtered peptide files are ordered (1) according to their total number of peptides (for example [P1, P2, P3]) and (2) as before with the first item is positioned last ([P2, P3, P1] in the previous example). The peptide data are then combined in pairs in these respective orders. The first one is called themasterfile.
  3. For each (master, slave) pair, the slave peptide file retention times are modelled according to the (original) master's retention times and slave peptides, not yet present in the master file are added to the master file.
  4. The finalmasterdatasets, containing their own peptides and the respective slave specific retention time adjusted peptides are returned as aMasterPeptidesinstance.

The resulting MasterPeptides instance can be further used for a complete master vs. peptides/Pep3D analysis, as described in Synapter, synergise or using the GUI (synapterGUI). To do so, it must be serialised (using the saveRDS function) with a .rds file extension, to be recognised (and loded) as a R object.

When several quantitation (or identification) files are combined as a master set to be mapped back against the inidividual final peptide files, the second master [P2, P3, P1] is used when analysing the peptide data that was first selected in the master generation (P1 above). This is to avoid aligning two identical sets of peptides (those of P1) and thus not being able to generate a valid retention time model. This is detected automatically for the user.

The two master peptides dataframes can be exported to disk as two csv files with writeMasterPeptides. The MasterPeptides object returned by makeMaster can be saved to disk (with save or saveRDS) and later reloaded (with load or readRDS) for further analysis.

References

Shliaha P.V., Bond N. J., Lilley K.S. and Gatto L., in prep.

See Also

See the Synapter class manual page for detailed information on filtering and modelling and the general algorithm implemented in the synapter package.

The estimateMasterFdr function allows to control false dicovery rate when combining several peptide files while maximising the number of identifications and suggest which combination of peptide files to use.

The vignette, accessible with synapterGuide() illustrates a complete pipeline using estimateMasterFdr and makeMaster.