as.DNAbin-methods: Coerces an object to a 'DNAbin' object

Description Usage Arguments Value Methods Examples

Description

This function coerces Dna object to DNAbin {ape} object .

Usage

1
2
## S4 method for signature 'Dna'
as.DNAbin(x, endgaps=TRUE)

Arguments

x

an object of class Dna.

endgaps

boolean; gaps at the end of the sequences are included if this is TRUE.

Value

an object of class DNAbin.

Methods

signature(x = "Dna")

coerces a Dna object to a DNAbin object.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Coercing a Dna object to a DNAbin object.
data("dna.obj")

x<-dna.obj
dBin<-as.DNAbin(x)
dBin

#gaps at the end removed
dBin<-as.DNAbin(x, endgaps=FALSE)
dBin

haplotypes documentation built on Feb. 28, 2020, 5:08 p.m.