[R-sig-eco] mrpp between pairs of factor levels

cristabel.duran at waldbau.uni-freiburg.de cristabel.duran at waldbau.uni-freiburg.de
Fri Sep 24 12:18:24 CEST 2010


Dear list,

I'm performing a mrpp analysis for my data (spp), the
grouping factor is mhab.
mhab has five levels: "b"      "br"     "c"      "nd"
    "nongap" "t" 

So, for a mrpp with factor mhab with all levels I'm doing:
mrpp(data=spp, grouping=mhab, dist="bray",
permutations=1000)

BUT now I want is to perform a mrpp with only levels "b"
and "nd".

I tried several ways without success:
mrpp(data=spp, grouping=c(mhab=="b" & "nd") , dist="bray",
permutations=1000)
mrpp(data=spp, grouping=c(mhab=="b" & mhab=="nd") ,
dist="bray", permutations=1000)
mrpp(data=spp, grouping=levels(which(envno34$mhab== "b") &
which(envno34$mhab== "b")), dist="bray", permutations=1000)

I got this errors:
- Error in x * w : non-numeric argument to binary operator
- Error in levels(mhab(which(mhab == "b") & which(mhab ==
 : 
   attempt to apply non-function
- Error in mhab == "b" & "nd" : 
   operations are possible only for numeric, logical or
complex types
...etc...etc..

I think it should be possible to choose the factor levels
which I want to work with, otherwise I should fix this
issue from 
my species and environmental matrices.

I appreciate your help!
Thank you :-)
Cristabel.

Cristabel Durán Rangel. PhD Student.
Institute of Silviculture. Faculty of Forest and
Environmental Sciences. University of Freiburg.
Germany
Telf: +49 (761) 203 8604 (ofc) 

„Man lernt die Physiognomie einer Landschaft desto besser
kennen, je genauer man die einzelnen Züge auffaßt, sie
untereinander vergleicht und so auf dem Wege der Analysis
den Quellen der Genüsse nachgeht, die uns das große
Naturgemälde bietet.“
				Alexander von Humboldt, 1799



More information about the R-sig-ecology mailing list