# [R] polr question

Troels Ring tring at mail1.stofanet.dk
Sat Mar 11 22:51:31 CET 2000

```Dear friends.
Do Polr in Mass change the sign of the coefficients ? Example (McCullagh 1980)
options(contrasts=c("contr.treatment","contr.poly"))
library(Mass)
freq <- c(19,29,24,497,560,269)
yy <- ordered(gl(3,1,6))
z4 <- polr(yy~x,weights=freq)
> z4
Call:
polr(formula = yy ~ x, weights = freq)

Coefficients:
x2
-0.6026492

Intercepts:
1|2        2|3
-1.1111584  0.7600705

Residual Deviance: 2955.49
AIC: 2961.49

- since as specified the logit for the non-carrier for being in the lower categories is higher ?
as also got from Lindsey's library:
library(gnlm)
y <- c(0:2,0:2) #must start at zero
x <- gl(2,3,6)
z3 <- ordglm(y~x,weights=freq)
z3
Call:
ordglm(y ~ x, weights = freq)

-Log likelihood    1477.747
AIC                1480.747
Deviance           0.3022138
df                 3
Iterations         4

Location coefficients
estimate    s.e.
(Intercept)   -1.1120  0.2255
x2             0.6035  0.0676

Intercept contrasts
estimate    s.e.
b[2]     1.871  0.2225

Correlation matrix
1        2        3
1  1.0000 -0.96836 -0.17098
2 -0.9684  1.00000  0.06321
3 -0.1710  0.06321  1.00000

--which also gives the correlation.

The fits are otherwise very similar, but why the difference in coefficients ?

Troels Ring, M.D
Department of Nephrology
Aalborg, Denmark
tring at mail1.stofanet.dk

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._

```