cdsfile2aafile: cdsfile2aafile

View source: R/cdsfile2aafile.R

cdsfile2aafileR Documentation

cdsfile2aafile

Description

This function translates a cds fasta file into an aa fasta file.

Usage

cdsfile2aafile(
  infile,
  outfile,
  shorten = FALSE,
  frame = 1,
  framelist = NULL,
  genetic.code = NULL
)

Arguments

infile

cds fasta file [mandatory]

outfile

aa fasta file [mandatory]

shorten

shorten all sequences to multiple of three [default: FALSE]

frame

indicates the first base of a the first codon [default: 1]

framelist

supply vector of frames for each entry [default: NULL]

genetic.code

The genetic code to use for the translation of codons into Amino Acid letters [default: NULL]

Value

aa fasta file

Author(s)

Kristian K Ullrich

See Also

cds2aa

Examples

## define file path
cdsfile <- system.file("fasta", "ath.cds.fasta.gz", package="CRBHits")
## create empty temp file
aafile <- tempfile()
## convert input CDS fasta file into AA fasta file
cdsfile2aafile(cdsfile, aafile)
aa <- Biostrings::readAAStringSet(aafile)
aa

kullrich/CRBHits documentation built on March 29, 2024, 11:34 a.m.