list2dist: Convert pairwise list to distance matrix

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

View source: R/list2dist.R

Description

Convert pairwise list to distance matrix

Usage

1
list2dist(dat)

Arguments

dat

dataframe with three columns

Details

Dataframe with first column as the column names in the distance matrix, second column as the rownames in the distance matrix, third column the values.

Value

distance matrix

Author(s)

Jinlong Zhang jinlongzhang01@gmail.com

References

Tuomisto, H. (2003). "Dispersal, Environment, and Floristic Variation of Western Amazonian Forests." Science 299(5604): 241-244.

See Also

dist2list

Examples

1
2
3
4
5
##list2dist() example
x <- matrix(rnorm(100), nrow=5)
sampledata <- dist(x)
ddd <- dist2list(sampledata)
list2dist(ddd)

spaa documentation built on May 19, 2017, 11:26 p.m.

Search within the spaa package
Search all R packages, documentation and source code