Rao: Functions to compute Rao’s entropy

View source: R/Rao.R

RaoR Documentation

Functions to compute Rao’s entropy

Description

Set of functions to estimate Rao’s functional entropy. Rao calculates the Rao entropy, RaoVar the variance of the Rao estimator, RaoPow the Rao entropy of order q, and RaoPowProfile the functional Rao entropy profile for the given set of exponents.

Usage

Rao(dst, w=NULL)
RaoVar(dst,w=NULL)
RaoPow(dst,q,w=NULL)
RaoPowProfile(dst,w=NULL,q=NULL)

Arguments

dst

A "dist" object, output of the DNA.dist function.

w

An optional numeric vector with the haplotype counts. When w is NULL the same weight is given to each haplotype.

q

Exponent. A single value for Rao, RaoVar and RaoPow. A vector of values for RaoPowProfile. The default value for RaoPowProfile is a set of exponents to obtain a smooth profile.

Value

A single value for Rao, RaoVar and RaoPow. A vector of values for RaoPowProfile corresponding to each exponent in vector q.

Author(s)

Mercedes Guerrero-Murillo and Josep Gregori

References

Gregori J, Perales C, Rodriguez-Frias F, Esteban JI, Quer J, Domingo E. Viral quasispecies complexity measures. Virology. 2016 Jun;493:227-37. doi: 10.1016/j.virol.2016.03.017. Epub 2016 Apr 6. Review. PubMed PMID: 27060566.

Gregori J, Salicrú M, Domingo E, Sanchez A, Esteban JI, Rodríguez-Frías F, Quer J. Inference with viral quasispecies diversity indices: clonal and NGS approaches. Bioinformatics. 2014 Apr 15;30(8):1104-1111. Epub 2014 Jan 2. PubMed PMID: 24389655.

Pavoine, S. (2005). Méthodes statistiques pour la mesure de la biodiversité. UMR CNRS 5558 «Biométrie et Biologie Evolutive».

See Also

DNA.dist, ReadAmplSeqs

Examples


# Load haplotype alignment with abundances.
filepath<-system.file("extdata","ToyData_10_50_1000.fna", package="QSutils")
lst <- ReadAmplSeqs(filepath,type="DNA")
# DNA pairwise distances.
dst <- DNA.dist(lst$hseqs,model="N")

Rao(dst,lst$nr)
RaoVar(dst,lst$nr)
RaoPow(dst,2,lst$nr)
RaoPowProfile(dst,lst$nr,c(0:4,Inf))
RaoPowProfile(dst,lst$nr)

VHIRHepatiques/QSutils documentation built on April 27, 2024, 10:29 p.m.