buildLinkerDf: Constructs a linkerDf that can be used as input when...

Description Usage Arguments Details Value Examples

View source: R/buildlinkerdf.R

Description

Constructs a 4 column data.frame that contains the relationships between proteins and peptides: which peptides belong to which proteins and vice versa.

Usage

1
buildLinkerDf(protIDs, pepIDs, protToPep, pepToProt)

Arguments

protIDs

a character vector with unique ids that can be mapped back to the proteins. Must be in the same order as in the rowDataProt data frame.

pepIDs

a character vector with unique ids that can be mapped back to the peptides. Must be in the same order as in the rowDataPep data frame.

protToPep

a list with the same length as the number of protIDs. Every entry of the list contains the peptide ids that are linked to that protein. Items in the list must be in the same order as in protIDs.

pepToProt

a list with the same length as the number of pepIDs Every entry of the list contains the protein ids that are linked to that peptide. Items in the list must be in the same order as in pepIDs

Details

This data frame is used in several functions and operations involving the SilacProteomicsExperiment class. Especially in object merging and subsetting. The arguments protIDs and pepIDs are mandatory, but only one of the protToPep or pepToProt arguments is necessary to build the linkerDf.

Value

A data.frame with the following 4 columns:

protID

Column with the protein IDs.

pepID

Column with the peptide IDs.

protRow

Column with row numbers of protein IDs.

protID

Column with the row numbers of peptide IDs.

Examples

1
2
3
4
5
6
7
## list with the relationships
protein_to_peptide <- list(A = c('a', 'b'), B = c('c'), C = c('d', 'e'))
## function to build the data.frame
linkerDf <- buildLinkerDf(protIDs = LETTERS[1:3],
                         pepIDs  = letters[1:5],
                         protToPep = protein_to_peptide)
linkerDf

pulsedSilac documentation built on Nov. 8, 2020, 5:13 p.m.