"Haplotype" in the Package haplotypesS4 class to store haplotype information.
Objects can be created by calls of the form new("Haplotype", haplist, hapind, uniquehapind, sequence, d, freq, nhap), however use function haplotype instead.
haplist:Object of class "list", containing the names of individuals that share the same haplotype.
hapind:Object of class "list", containing the index of individuals that share the same haplotype.
uniquehapind:Object of class "numeric", containing the index of the first occurrence of unique haplotypes.
sequence:Object of class "matrix" if present, giving the DNA sequence matrix of unique haplotypes.
d:Object of class "matrix", giving the absolute pairwise character difference matrix of unique haplotypes.
freq:Object of class "numeric", giving the haplotype frequencies.
nhap:Object of class "numeric", giving the total number of haplotypes.
signature(x = "Haplotype"): if Haplotype object contains dna sequences, coerces an object of class Haplotype to an object of class Dna, else returns an error message.
signature(x = "Haplotype"): assigns slots of an object Haplotype to list elements.
signature(x = "Haplotype"): creates a matrix with haplotypes as rows, grouping factor (populations, species, etc.) as columns and abundance as entries.
signature(x = "Haplotype"): reorders haplotypes according to the ordering factor.
signature(x = "Haplotype"): returns the number of haplotypes.
signature(x = "Parsimnet", y = "Haplotype"): plot pie charts on statistical parsimony network.
signature(x = "Parsimnet", y = "Haplotype"): add legends to pie charts produced using pieplot.
signature(object = "Haplotype"): displays the object briefly.
Caner Aktas, caktas.aca@gmail.com