read_alignment {agvgd} | R Documentation |
Read a protein sequence multiple alignment
Description
Reads a protein sequence multiple alignment (PSMA) from either a set of pre-bundled alignments, by gene name, or from a Multi-FASTA file.
Usage
read_alignment(
gene = c("ATM", "BRCA1", "BRCA2", "CHEK2", "MRE11", "MSH6", "NBN", "PALB2", "PMS2",
"RAD50", "RAD51", "XRCC2"),
file = NULL
)
Arguments
gene |
The gene name for which an alignment is provided with this
package. Use the function |
file |
The path to a Multi-FASTA file. If this argument is given, it
takes precedence over the |
Value
An alignment object; essentially, a character matrix, whose elements are protein residues in one-letter notation. Rows are sequences and columns are alignment positions.
Examples
# Read in the alignment for the gene XRCC2
read_alignment('XRCC2')
# Also read in the alignment for the gene XRCC2, but now by specifying
# directly the path to the file.
path <- system.file("extdata", alignment_file("XRCC2"), package = "agvgd")
read_alignment(file = path)
[Package agvgd version 0.1.2 Index]