Description Usage Arguments Value Examples
Export Transcriptome as FASTA
1 | exportFASTA(txdb, genome, file, ...)
|
txdb |
a |
genome |
a |
file |
a string for output FASTA file. File names ending in ".gz" will automatically use gzip compression. |
... |
additional arguments to pass through to
|
The txdb
argument is invisibly returned.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | library(TxDb.Scerevisiae.UCSC.sacCer3.sgdGene)
library(BSgenome.Scerevisiae.UCSC.sacCer3)
## load annotation and genome
txdb <- TxDb.Scerevisiae.UCSC.sacCer3.sgdGene
sacCer3 <- BSgenome.Scerevisiae.UCSC.sacCer3
## restrict to 'chrI' transcripts (makes for briefer example runtime)
seqlevels(txdb) <- c("chrI")
## last 500 nts per tx
txdb_w500 <- truncateTxome(txdb)
## export uncompressed
outfile <- tempfile("sacCer3.sgdGene.w500", fileext=".fa")
exportFASTA(txdb_w500, sacCer3, outfile)
## export compressed
outfile <- tempfile("sacCer3.sgdGene.w500", fileext=".fa.gz")
exportFASTA(txdb_w500, sacCer3, outfile)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.