dnastring2dnabin: dnastring2dnabin

View source: R/dnastring2dnabin.R

dnastring2dnabinR Documentation

dnastring2dnabin

Description

This function converts a DNAStringSet into an ape DNAbin.

Usage

dnastring2dnabin(dna)

Arguments

dna

DNAStringSet [mandatory]

Value

An object of class DNAbin

Author(s)

Kristian K Ullrich

See Also

as.alignment as.DNAbin.alignment

Examples

## define two cds sequences
cds1 <- Biostrings::DNAString("ATGCAACATTGC")
cds2 <- Biostrings::DNAString("ATG---CATTGC")
cds1.cds2.aln <- c(Biostrings::DNAStringSet(cds1),
    Biostrings::DNAStringSet(cds2))
## convert into DNAbin
#dnastring2dnabin(cds1.cds2.aln)
cds1.cds2.aln |> dnastring2dnabin()

kullrich/MSA2dist documentation built on Nov. 14, 2024, 5:39 p.m.