2

I am running a logistic regression. Treatment is a factor with 3 levels. I am assuming that intercept is one of these 3 levels (negative control in this case). Is there a reason the equation is splitting the predictor variable like this?

Call:
glm(formula = propgfp ~ treatment, family = quasibinomial, data = frass4glm)

Deviance Residuals: Min 1Q Median 3Q Max
-2.7631 -0.0001 0.6031 0.6964 0.8529

Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) -19.87 3390.23 -0.006 0.995 treatmentFrass 22.64 3390.23 0.007 0.995 treatmentPositive 22.64 3390.23 0.007 0.995

(Dispersion parameter for quasibinomial family taken to be 1.324805)

Null deviance: 100.322  on 34  degrees of freedom

Residual deviance: 25.863 on 32 degrees of freedom AIC: NA ```

  • 2
    You have a predictor with three levels. Two levels plus one (the intercept) is three. What is giving you trouble? – Sycorax Apr 03 '23 at 19:34

1 Answers1

1

Your variable has three levels. One is subsumed by the intercept. One is the binary variable treatmentFrass that is $1$ when the treatment is Frass and zero otherwise. One is the binary treatmentPositive that is $1$ when the treatment is Positive and zero otherwise. This way, only the intercept is active when the treatment is neither Frass nor Positive; the parameter on treatmentFrass gives you the estimated difference in the outcome between the omitted category (that is subsumed by the intercept) and the Frass group; and the parameter on treatmentPositive gives you the estimated difference in the outcome between the omitted category (that is subsumed by the intercept) and the Positive group.

This is the same as why a three-factor variable in an ANOVA regression is split into two categories with the third subsued by the intercept.

Dave
  • 62,186
  • @LiamTSullivan It would help if you explained what you meant by "the effect of treatment as a whole". This makes it sound like you lack a control group. – Dave Apr 03 '23 at 20:21
  • Fair point. Thanks for the correction. The positive and negative are the respective controls, so I am looking for the effect of the frass treatment against these two. I think I see my issue. – Liam T Sullivan Apr 03 '23 at 20:30
  • For clarity. I misunderstood your explanation initially, thanks all for the help here! Statistics is a weak point for me and I am glad to have your input. – Liam T Sullivan Apr 03 '23 at 21:00