compute_accession_coverage: Compute accession coverage from identified peptides

Description Usage Arguments Value Author(s) Examples

Description

Given a list of accession and peptide pairs, computes the proportion of amino acid sequence covered by the listed peptides for each accession.

Usage

1
2
3
4
    compute_accession_coverage(object,
                               fasta,
                               accession_col="accession",
                               pepSeq_col="pepSeq")

Arguments

object

An instance of class MSnID.

fasta

(AAStringSet object) Protein sequences read from a FASTA file. Names must match protein/accesison IDs in the accesson column of the MSnID object.

accession_col

(character) Name of the accession column.

pepSeq_col

(character) Name of the peptide sequence column.

Value

MSnID object with an extra column percentAAcoverage with values in 0-100.

Author(s)

Michael Nestor michael.nestor@pnnl.gov

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
m <- MSnID(".")
mzids <- system.file("extdata","phospho.mzid.gz",package="MSnID")
m <- read_mzIDs(m, mzids)

# read fasta
fst_path <- system.file("extdata","for_phospho.fasta.gz",package="MSnID")
library(Biostrings)
fst <- readAAStringSet(fst_path)

# remove decoy because they are not in this small fasta file
m <- apply_filter(m, "!isDecoy")
# compute accession coverage
m <- compute_accession_coverage(m, fst)

head(unique(subset(psms(m), select=c("accession", "percentAACoverage"))))

# clean-up cache
unlink(".Rcache", recursive=TRUE)

vladpetyuk/MSnID documentation built on June 25, 2021, 6:35 a.m.