Title: | Test for Parallel Regression Assumption |
---|---|
Description: | Tests the parallel regression assumption for ordinal logit models generated with the function polr() from the package 'MASS'. |
Authors: | Benjamin Schlegel [aut,cre], Marco Steenbergen [aut] |
Maintainer: | Benjamin Schlegel <[email protected]> |
License: | GPL (>=2) |
Version: | 0.3-2 |
Built: | 2025-02-12 04:40:47 UTC |
Source: | https://github.com/benjaminschlegel/brant |
The function calculates the brant test for ordinal logit models to test the parallel regression assumption.
brant(model,by.var=F)
brant(model,by.var=F)
model |
the polr-Object generated with polr() |
by.var |
OPTIONAL if set to true, the tests are made for each variable instead of each coefficient. Default: FALSE. |
The function calculates the brant test for parallel regression assumption. The brant test was published by Brant (1990). The function works with models generated with the function polr() from the package 'MASS'.
The output is the brant test, which shows if the parallel assumption holds or not.
Benjamin Schlegel, [email protected]
Brant, R. (1990) Assessing proportionality in the proportional odds model for ordinal logistic regression. Biometrics, 46, 1171–1178.
data = MASS::survey data$Smoke = ordered(MASS::survey$Smoke,levels=c("Never","Occas","Regul","Heavy")) model1 = MASS::polr(Smoke ~ Sex + Height, data=data, Hess=TRUE) summary(model1) brant(model1)
data = MASS::survey data$Smoke = ordered(MASS::survey$Smoke,levels=c("Never","Occas","Regul","Heavy")) model1 = MASS::polr(Smoke ~ Sex + Height, data=data, Hess=TRUE) summary(model1) brant(model1)