read.fas {haplotypes} | R Documentation |
Read sequences from a file in FASTA format
Description
Read DNA sequences from a file in FASTA Format.
Usage
read.fas(file)
Arguments
file |
the name of the file, which the sequence in the FASTA format is to be read from. If it does not contain an absolute path, the file name is relative to the current working directory,
|
Value
read.fas
returns an object of class Dna
.
Note
By default, valid characters are "A","C","G","T","a","c","g","t","-","?" for the class Dna
. Numeric entries (integers) between 0-5 will be converted to "?","A","C","G","T","-", respectively. Invalid characters will be replaced with "?" with a warning message.
Author(s)
Caner Aktas, caktas.aca@gmail.com
See Also
Examples
##Reading example file.
f<-system.file("example.fas",package="haplotypes")
# invalid character 'N' was replaced with '?' with a warning message
x<-read.fas(file=f)
# an object of class 'Dna'
x
[Package haplotypes version 1.1.3.1 Index]