FastaFile-class: FastaFile objects

Description Usage Arguments FastaFile objects Author(s) See Also

Description

These functions support the import and export of the Fasta sequence format, using the Biostrings package.

Usage

1
2
3
4
5
6
7
8
## S4 method for signature 'FastaFile,ANY,ANY'
import(con, format, text,
           type = c("DNA", "RNA", "AA", "B"), ...)

## S4 method for signature 'ANY,FastaFile,ANY'
export(object, con, format, ...)
## S4 method for signature 'XStringSet,FastaFile,ANY'
export(object, con, format, ...)

Arguments

con

A path or FastaFile object. URLs and connections are not supported. If con is not a FastaFile, either the file extension or the format argument needs to be “fasta”. Compressed files (“gz”, “bz2” and “xz”) are handled transparently.

object

The object to export, should be an XStringSet or something coercible to a DNAStringSet, like a character vector.

format

If not missing, should be “fasta”.

text

If con is missing, a character vector to use as the input

type

Type of biological sequence.

...

Arguments to pass down to writeXStringSet (export) or the readDNAStringSet family of functions (import).

FastaFile objects

The FastaFile class extends RTLFile and is a formal represention of a resource in the Fasta format. To cast a path, URL or connection to a FastaFile, pass it to the FastaFile constructor.

Author(s)

Michael Lawrence

See Also

These functions are implemented by the Biostrings writeXStringSet (export) and the readDNAStringSet family of functions (import).

See export-methods in the BSgenome package for exporting a BSgenome object as a FASTA file.


rtracklayer documentation built on Nov. 8, 2020, 6:50 p.m.