Learn R Programming

ade4 (version 1.5-2)

dist.prop: Computation of Distance Matrices of Percentage Data

Description

computes for percentage data some distance matrices.

Usage

dist.prop(df, method = NULL, diag = FALSE, upper = FALSE)

Arguments

df
a data frame containing only positive or null values, used as row percentages
method
an integer between 1 and 5. If NULL the choice is made with a console message. See details
diag
a logical value indicating whether the diagonal of the distance matrix should be printed by `print.dist'
upper
a logical value indicating whether the upper triangle of the distance matrix should be printed by `print.dist'

Value

  • returns a distance matrix, object of class dist

encoding

latin1

Details

[object Object],[object Object],[object Object],[object Object],[object Object]

References

Edwards, A. W. F. (1971) Distance between populations on the basis of gene frequencies. Biometrics, 27, 873--881.

Manly, B. F. (1994) Multivariate Statistical Methods. A primer., Second edition. Chapman & Hall, London.

Nei, M. (1972) Genetic distances between populations. The American Naturalist, 106, 283--292.

Examples

Run this code
data(microsatt)
w <- microsatt$tab[1:microsatt$loci.eff[1]]
par(mfrow = c(2,2))
scatter(dudi.pco(lingoes(dist.prop(w,1)), scann = FALSE))
scatter(dudi.pco(lingoes(dist.prop(w,2)), scann = FALSE))
scatter(dudi.pco(dist.prop(w,3), scann = FALSE))
scatter(dudi.pco(lingoes(dist.prop(w,4)), scann = FALSE))
par(mfrow = c(1,1))

Run the code above in your browser using DataLab