michael.eisenring at agroscope.admin.ch
2015-Dec-22 16:18 UTC
[R] How to conduct a PERMANOVA using a dissimilarity matrix
Dear R-List members, I have to compare how similar two types of forest (old growth=O) and (young forest=Y) in terms of moth communities are. I sampled moths at 4 O and 4 Y sites. I need to analyse the data using a PERMANOVA approach. But I am having a really hard time to do this in R. I found out that I need to create a dissimilarity matrix and read this matrix then into R to conduct a one-way Permanova with forest type (O or Y) as factor. The package vegan with the function "adonis" seems to be able to do a permanova. I created the matrix (based on Soerenson (dis)similarities) and imported it into R. Could anyone help me with the next step? How can I conduct a permanova on my dataset? In the end I would need an R value and significance level telling me if community compositions differ significantly between sites. Below is my code (not too much) and the data for the matrix. #dput for matrix: structure(c("", "O", "Y", "Y", "Y", "O", "O", "Y", "O", "O", "0", "0.544", "0.519", "0.533", "0.481", "0.548", "0.518", "0.479", "Y", "0.544", "0", "0.383", "0.416", "0.383", "0.358", "0.434", "0.399", "Y", "0.519", "0.383", "0", "0.398", "0.359", "0.392", "0.401", "0.374", "Y", "0.533", "0.416", "0.398", "0", "0.398", "0.399", "0.358", "0.348", "O", "0.481", "0.383", "0.359", "0.398", "0", "0.37", "0.317", "0.354", "O", "0.548", "0.358", "0.392", "0.399", "0.37", "0", "0.39", "0.365", "Y", "0.518", "0.434", "0.401", "0.358", "0.317", "0.39", "0", "0.371", "O", "0.479", "0.399", "0.374", "0.348", "0.354", "0.365", "0.371", "0"), .Dim = c(9L, 9L), .Dimnames = list(NULL, c("V1", "V2", "V3", "V4", "V5", "V6", "V7", "V8", "V9"))) #Code #load dissimilarity matrix (based on Soerenson similarity) moth_dta<-read.csv("Geo_sorenson_8.csv",header=T,sep=";")#Creates matrix from imported data moth_dta<-as.matrix(moth_dta) moth_dta library(vegan) Thank you very much, Michael Eisenring Michael, Msc. PhD Student Federal Department of Economic Affairs, Education and Research EAER Institute of Sustainability Sciences ISS Biosafety Reckenholzstrasse 191, CH-8046 Z?rich Tel. +41 44 37 77181 Fax +41 44 37 77201 michael.eisenring at agroscope.admin.ch<mailto:michael.eisenring at agroscope.admin.ch> www.agroscope.ch<http://www.agroscope.ch/> [[alternative HTML version deleted]]