ConsSeq: Consensus sequence given an alignment and frequencies

Description Usage Arguments Details Value Author(s) See Also Examples

Description

ConsSeq determines the consensus sequence from a set of haplotypes.

Usage

1
ConsSeq(seqs, w=NULL)

Arguments

seqs

DNAStringSet or AAStringSet object with the haplotype sequences.

w

An optional numeric vector with the haplotype counts.

Details

The most frequent nucleotide or amino acid at each position is taken. No IUPAC ambiguity codes are considered; in the case of ties, the consensus nucleotide is decided randomly.

Value

Character vector with the consensus sequence.

Author(s)

Mercedes Guerrero-Murillo and Josep Gregori

See Also

ReadAmplSeqs

Examples

1
2
3
4
filepath<-system.file("extdata","ToyData_10_50_1000.fna", package="QSutils")
lst <- ReadAmplSeqs(filepath,type="DNA")

ConsSeq(lst$hseqs,lst$nr)

VHIRHepatiques/QSutils documentation built on May 8, 2019, 1:44 p.m.