capscale
) or non-parametric multivariate analysis of variance (adonis
).
nested.anova.dbrda(formula, data, method="euc", add=FALSE, permutations=100, warnings=FALSE)
nested.npmanova(formula, data, method="euc", permutations=100, warnings=FALSE)
nested.anova.dbrda
only) distance matrix on the left-hand side and two categorical variables on the right-hand side (with the second variable assumed to be nested within the first). vegdist
: partial match to "manhattan", "euclidean", "canberra", "bray", "kulczynski", "jaccard", "gower", "morisita", "horn" or "mountford". This argument is ignored in case that the left-hand side of the formula already is a distance matrix. nested.anova.dbrda
proceeds via capscale
, whereas nested.npmanova
proceeds via adonis
. Both methods are complementary to each other as nested.npmanova
always provides correct F-ratios and estimations of significance, whereas nested.anova.dbrda
does not provide correct F-ratios and estimations of significance when negative eigenvalues are encountered or constants are added to the distance matrix, but always provides an ordination diagram.
The F-ratio for the main factor is estimated as the mean square of the main factor divided by the mean square of the nested factor. The significance of the F-ratio of the main factor is tested by permuting entire blocks belonging to levels of the nested factor. The significance of the F-ratio of the nested factor is tested by permuting sample units within strata defined by levels of the main factor.Anderson, M.J. (2001). A new method for non-parametric multivariate analysis of variance. Austral Ecology, 26: 32-46.
McArdle, B.H. and M.J. Anderson. (2001). Fitting multivariate models to community data: A comment on distance-based redundancy analysis. Ecology, 82: 290-297.
## Not run:
# library(vegan)
# data(warcom)
# data(warenv)
# # use larger number of permutations for real studies
# nested.npmanova(warcom~rift.valley+popshort, data=warenv, method="jac",
# permutations=5)
# nested.anova.dbrda(warcom~rift.valley+popshort, data=warenv, method="jac",
# permutations=5)
# ## End(Not run)
Run the code above in your browser using DataLab