Skip to content
Prev 320540 / 398506 Next

Conditional CCA and Monte Carlo - Help!

MWilson <mjw029 <at> bucknell.edu> writes:
Help-tp4662572.html
randtest() is an ade4 function that only works with ade4 result
objects. That you found the hard way.  In vegan we have permutest: see
?permutest.cca. Some other similar functions are described together
with permutest.cca, but permutest() is similar to randtest.

ade4::randtest.cca and vegan:::permutest.cca work similarly and are
comparable with basic models, but there are following differences:

1) vegan uses ter Braak's pseudo-F statistic, whereas ade4 returns the
proportion constrained/all eigenvalues. These are similar to a
constant multiplier in non-conditional models and with "direct" or
"reduced" permutation models in vegan, but differ otherwise. The ade4
alternative is not good for partial models (but that does not matter
since ade4 has no partial models). The vegan:::permutest.cca function
returns items num and den (numerator and denominator) that can be used
to get the proportion of ade4.

2) vegan permutes response (community) data whereas ade4 permutes
constraints (environmental data).  This makes only difference in
partial (conditional) models or with some non-default permutation
strategies in vegan. However, because of this, ade4 and vegan results
are not identical with the same random number seed (with little
trickery this can be fixed, but that is hardly for
beginners). Permutation of community data is needed in analysis of
conditional (partial) models, and in some permutation strategies.

3) We do not call it Monte Carlo, but permutation. (Monte Carlo is too
expensive for me -- I prefer Menton). That may explain why Google did
not find it to you.

In general, you should not expect methods functions (such as
ade4::randtest.cca) to work across packages. In sometimes they do, but
in those cases the package authors have taken special care to make
their functions to work with alien objects. Not in this case. It
neither makes sense for ade4::randtest be able to handle vegan object
because randtest does not know what to do with contional (partial)
models. 

Cheers, Jari Oksanen