rda
), but it allows
non-Euclidean dissimilarity indices, such as Manhattan or
Bray--Curtis distance. Despite this non-Euclidean feature, the analysis
is strictly linear and metric. If called with Euclidean distance,
the results are identical to rda
, but capscale
will be much more inefficient. Function capscale
may be useful
with other dissimilarity measures, since Euclidean distances inherent in
rda
are generally poor with community datacapscale(formula, data, distance = "euclidean", comm = NULL, ...)
vegdist
used if the LHS of the formula
is a
data frame instead of dissimilarity matrix.formula
was a
dissimilarity matrix. This is not used if the LHS is a data
frame. If this is not supplied, the ``species scores'' are the axes
rda
.cmdscale
and (2) analyses these results using
rda
. If the user supplied a community data frame instead
of dissimilarities, the function will find the needed dissimilarity
matrix using vegdist
with specified
distance
. However, the method will accept dissimilarity
matrices from vegdist
, dist
, or any
other method producing similar matrices. The constraining variables can be
continuous or factors or both, they can have interaction terms,
or they can be transformed in the call. Moreover, there can be a
special term
Condition
just like in rda
and cca
so that ``partial'' CAP can be performed.The current implementation differs from the method suggested by Anderson & Willis (2003) in three major points:
cmdscale
, whereascapscale
uses axes
weighted by corresponding eigenvalues, so that the ordination
distances are best approximations of original dissimilarities. In
the original method, later ``noise'' axes are just as important as
first major axes.capscale
uses all axes with positive eigenvalues. The use of
subset is necessary with orthonormal axes to chop off some
``noise'', but the use of all axes guarantees that the results are
the best approximation of original dissimilarities.capscale
adds species scores as weighted sums
of (residual) community matrix (if the matrix is available), whereas
Anderson & Willis have no fixed method for adding species scores.capscale
with Euclidean
distances will be identical to rda
in eigenvalues and
in site, species and biplot scores (except for possible sign
reversal).
However, it makes no sense to use capscale
with
Euclidean distances, since direct use of rda
is much more
efficient. Even with non-Euclidean dissimilarities, the
rest of the analysis will be metric and linear.rda
, cca
, plot.cca
,
anova.cca
, vegdist
,
dist
, cmdscale
.data(varespec)
data(varechem)
vare.cap <- capscale(varespec ~ N + P + K + Condition(Al), varechem, dist="bray")
vare.cap
plot(vare.cap)
anova(vare.cap)
Run the code above in your browser using DataLab