[R-sig-eco] using Adonis for zero data

Gavin Simpson gavin.simpson at ucl.ac.uk
Wed Jun 30 13:41:43 CEST 2010


On Mon, 2010-06-21 at 15:45 +0100, Emma Stone wrote:
> Dear All,
> 
> I am running a multivariate ANOVA based on dissimilarities using the adonis 
> function in the VEGAN package in R. I have trying to assess the number and 
> types of bat mitigation used at sites as a function of three predictors. 
> The predictors are : number of bats (nobats= continuous), impact (factor 
> with 3 categories) and roost type(rtype = factor with 5 categories). There 
> are three responses which are count data: number of boxes, number of barns 
> and number of lofts.
> The problem is that I have a lot of zeros in the data and they are not all 
> integers.
> 
> I have been running the following code using euclidean distances but I am 
> not sure that it is ok to use Euclidean distances for count data with 
> zeros.

Are you interested in the magnitude - should abundant species dominate
the dissimilarity? - differences? Euclidean could be OK if you were
magnitude focussed but there are often better dissimilarities for
ecological data where absolute difference rather than squared
differences are used.

> adonis(resp~Impact+nobats+rtype,data=pred,method=euclidean,permutation=500)

Is that exactly how you ran this in R? If so it is incorrect; argument
'method' is supposed to be passed a character which is the name of the
dissimilarity coefficient you want to use, one provided by vegdist().
See ?vegdist for the available options.

> I have read that you can transform the distances with the following code
> dis <- vegdist(decostand(resp, "norm"), "euclid")

I doubt it, if you are interested in normalising the species as MARGIN =
1 be default for that method and that refers to rows. But it depends on
what you hope to achieve by transforming the sites/samples. If you want
the species to all have the same mean and variance, then

dis <- vegdist(scale(resp), "euclidean")

should do it but then the analysis will be focussed on the relative
abundance to some extent.

> so have done this and I do get a very difference result, but again I am not 
> sure that this is suitable.
> 
> I have tried running the model with different distance measures but it will 
> only run with the euclidean distance method.

Given that the default for 'method' is "bray" and vegan passes R CMD
check on a large number of systems, that comment is patently *not* true.

> Any help would be most appreciated.

If this doesn't sort your problem out, can you past back exactly the
commands you used and the output from R so we can diagnose what is going
on?

HTH

G

> Thanks
> 
> Emma
> 
> 
> ----------------------
> Emma Stone
> Postgraduate Researcher
> Bat Ecology and Bioacoustics Lab
> & Mammal Research Unit
> School of Biological Sciences,
> University of Bristol, Woodland Road,
> Bristol, BS8 1UG
> Email: emma.stone at bristol.ac.uk
> 
> _______________________________________________
> R-sig-ecology mailing list
> R-sig-ecology at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-ecology

-- 
%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%
 Dr. Gavin Simpson             [t] +44 (0)20 7679 0522
 ECRC, UCL Geography,          [f] +44 (0)20 7679 0565
 Pearson Building,             [e] gavin.simpsonATNOSPAMucl.ac.uk
 Gower Street, London          [w] http://www.ucl.ac.uk/~ucfagls/
 UK. WC1E 6BT.                 [w] http://www.freshwaters.org.uk
%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%~%



More information about the R-sig-ecology mailing list