1

My data (factors):

Y = 0 or 1 (0="no", 1="yes")  
A = A1, A2, A3   
B = B1, B2   
C = C1, C2, C3

When I run logistic regression model, I get coefficients:

    Estimate              Std. Error z value     Pr(>|z|)    
    (Intercept)           1.350e+00  5.349e-01   2.523 0.011635 *  
    A2                    6.268e-01  3.026e-01   2.071 0.038340 *  
    A3                    4.676e-01  3.243e-01   1.442 0.149411    
    B2                    1.472e+00  7.913e-01   1.861 0.062756 .  
    C2                    2.071e+00  8.752e-01   2.366 0.017970 *  
    C3                    3.353e+00  1.134e+00   2.957 0.003111 ** 

The A1,B1 and C1 are missing.. I read that R uses one of the levels as the reference. But I have a task to get all coefficients of factors, is it possible? Maybe there is another model where I got all the coefficients?

If I use spss or any other program, would the situation be the same? It doesn't depend on the program, yes?

rcat
  • 11
  • 3
  • 1
    When you use a factor variable with n levels as a regression coefficient, r creates n-1 dummy variables for you. As a result, the effect of A1 is captured within the intercept. A2 & A3 represent the deviation from A1. – svenhalvorson Apr 25 '19 at 12:49
  • So it does not depend on the model I apply? – rcat Apr 25 '19 at 12:59
  • 1
    relevant: https://stackoverflow.com/questions/41032858/lm-summary-not-display-all-factor-levels – user20650 Apr 25 '19 at 13:26
  • It's not possible to get coefficients for all the levels independently. Your model would be over-specified in that case. This is a fundamental reality of regression modeling. – MrFlick Apr 25 '19 at 15:22
  • if i use spss or any other program, would the situation be the same? It doesn't depend on the program, yes? – rcat May 16 '19 at 12:57

0 Answers0