goodness.metaMDS
find goodness of fit measure for
points in nonmetric multidimensional scaling, and function
stressplot
makes a Shepard
diagram.## S3 method for class 'metaMDS':
goodness(object, dis, ...)
stressplot(object, dis, pch, p.col = "blue", l.col = "red", lwd = 2,
...)
goodness
returns a vector of values. Function
stressplot
returns invisibly a Shepard
object.goodness.metaMDS
finds a goodness of fit statistic for
observations (points). This is defined so that sum of squared values
is equal to squared stress. Large values indicate poor fit. Function stressplot
is a wrapper to Shepard
function in
Both functions can be used both with metaMDS
and with
isoMDS
. With metaMDS
, the functions
try to reconstruct the dissimilarities using
metaMDSredist
, and dissimilarities should not be given.
With isoMDS
the dissimilarities must be given.
In either case, the functions inspect that dissimilarities are
consistent with current ordination, and refuse to analyse inconsistent
dissimilarities. Function goodness.metaMDS
is generic in
vegan
, but you must spell its name completely with
isoMDS
which has no class.
metaMDS
, isoMDS
,
Shepard
.data(varespec)
mod <- metaMDS(varespec)
stressplot(mod)
gof <- goodness(mod)
gof
plot(mod, display = "sites", type = "n")
points(mod, display = "sites", cex = gof/2)
Run the code above in your browser using DataLab