apply_filter: Filters the MS/MS identifications

Description Usage Arguments Details Value Author(s) See Also Examples

Description

Filter out peptide-to-spectrum MS/MS identifications.

Usage

1
    apply_filter(msnidObj, filterObj)

Arguments

msnidObj

An instance of class "MSnID".

filterObj

Either an instance of MSnIDFilter class or a "character".

Details

filterObj argument evaluated to a "logical" for each entry of the MS/MS results table.

Value

Returns an instance of "MSnID" class with with peptide-to-spectrum matches that pass criteria defined in filterObj argument.

Author(s)

Vladislav A Petyuk vladislav.petyuk@pnnl.gov

See Also

MSnID evaluate_filter

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
data(c_elegans)

## Filtering using string:
msnidObj <- assess_termini(msnidObj, validCleavagePattern="[KR]\\.[^P]")
table(msnidObj$numIrregCleavages)
# getting rid of any other peptides except fully tryptic
msnidObj <- apply_filter(msnidObj, "numIrregCleavages == 0")
show(msnidObj)

## Filtering using filter object:
# first adding columns that will be used as filters
msnidObj$msmsScore <- -log10(msnidObj$`MS-GF:SpecEValue`)
msnidObj$mzError <- abs(msnidObj$experimentalMassToCharge - 
                        msnidObj$calculatedMassToCharge)
# setting up filter object
filtObj <- MSnIDFilter(msnidObj)
filtObj$msmsScore <- list(comparison=">", threshold=10.0)
filtObj$mzError <- list(comparison="<", threshold=0.1) # 0.1 Thomson
show(filtObj)
# applying filter and comparing MSnID object before and after
show(msnidObj)
msnidObj <- apply_filter(msnidObj, filtObj)
show(msnidObj)

MSnID documentation built on Nov. 8, 2020, 8:03 p.m.