Using the excellent quantreg
package and testing hypothesis of equal slopes between quantile 0.1 and 0.9 using standard anova
function.
model <- food ~ income
anova(rq(model,tau=0.1), rq(model,tau=0.9))
A zero p-val leads us to reject the null hypothesis that the slopes of q1 and q9 are equal
When running the same anova to compare quantile regression against OLS, there is an error
anova(rq(model,tau=0.5), lm(model))
Any suggestions?