JSDt_cluster: Clustering on the Jensen-Shannon distance between...

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

View source: R/JSDt_cluster.R

Description

Computes the Jensen-Shannon distance metric between spectral density profiles of phylogenetic trait data and clusters on those distances.

Usage

1
JSDt_cluster(phylo,mat,plot=F)

Arguments

phylo

an object of type 'phylo' (see ape documentation)

mat

a matrix of trait data with one trait per column and rows aligned to phylo tips

plot

plot hierarchical cluster in a new window

Value

plots a heatmap and hierarchical cluster with bootstrap support (>0.9) and outputs results of the k-medoids clustering on the optimal number of clusters in the form of a list with the following components

clusters

a list with the following components: size, max_diss, av_diss, diameter, and separation

J-S matrix

a matrix providing the Jensen-Shannon distance values between pairs of phylogenetic trait data

cluster assignment

a table that lists for each trait its cluster assignment and silhouete width

Author(s)

E Lewitus

References

Lewitus, E., Morlon, H. (2019) Characterizing and comparing phylogenetic trait data from their normalized Laplacian spectrum, bioRxiv doi: https://doi.org/10.1101/654087

See Also

spectR_t

Examples

1
2
3
4
5
data(Cetacea)
n<-length(Cetacea$tip.label)
mat<-replicate(20, rnorm(n)) 
colnames(mat)<-1:dim(mat)[2]
JSDt_cluster(Cetacea,mat)

RPANDA documentation built on Nov. 10, 2021, 9:08 a.m.