[R] anova.rq in quantile regression

Tomas tdomingu at staffmail.ed.ac.uk
Wed Feb 24 13:52:19 CET 2010


Dear list


I'm trying to test for differences in slopes of the 95% quantile 
regression fitted to two distinct subsets of my data set, as bellow:

grx <- leaf.nitrogen
gry <- leaf.photosynthesis

ab1<- rq(gry[TRIP=="CAM"] ~ grx[TRIP=="CAM"],tau=.95)
ab2<- rq(gry[TRIP=="WA"] ~ grx[TRIP=="WA"],tau=.95)

When I try an anova(ab1,ab2), I get the following error message:

Error in anova.rqlist(object, ...) :
   Models don't all have the same response variable

I don't fully understand this and any tips on how to get around this?

Thanks in advance,
Tomas

-- 
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.



More information about the R-help mailing list