Question

"Betadisper" calculates the Non-euclidean distances between objects and their group centroids by reducing the original distances to principal coordinates. It is a multivariate analogue of Levene's test for homogeneity of variances. http://cc.oulu.fi/~jarioksa/softhelp/vegan/html/betadisper.html

My question, I would like to extract the values for the distance of each sample point(object) to the centroid in a list, which would be equivalent to the data used for the boxplot available in Betadisper. How could I do that?

x= betadisper(d, group, type = c("centroid”))
boxplot(x)

Thanks!

Was it helpful?

Solution

See str(x) and you will find it:

x$distances
with(x, boxplot(distances~group))

hth

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top