refseq_AAmol_wt: Extract the molecular weight from a protein accession

View source: R/refseq_AAmol_wt.R

refseq_AAmol_wtR Documentation

Extract the molecular weight from a protein accession

Description

refseq_AAmol_wt() Parses a protein accession output (RefSeq format) and extract the molecular weight (in Daltons).

Depending on the function, available accessions in refseqR include RefSeq models with the prefixes XM_ (mRNA), XR_ (non-coding RNA), and XP_ (protein), as well as subsequently curated RefSeq records with NM_, NR_, or NP_ accession prefixes.

Usage

refseq_AAmol_wt(protein)

Arguments

protein

A character string of the protein id.

Details

First, get the character vector containing the fetched record. Then, this function parses the fetched record and returns the molecular weight.

Value

A numeric vector representing the molecular weight of the protein.

Author(s)

Jose V. Die

See Also

refseq_RNA2protein to obtain the protein ids encoded by a set of transcript ids.

Examples

 # Get the molecular weight from a single protein accession
 protein <- "XP_020244413"
 refseq_AAmol_wt(protein)


 # Get the molecular weight from from a set of protein accessions
 protein = c("XP_004487758", "XP_004488550")
 sapply(protein, function(x) refseq_AAmol_wt(x), USE.NAMES = TRUE)


refseqR documentation built on Oct. 30, 2024, 1:06 a.m.