Quantcast
Channel: Statalist
Viewing all articles
Browse latest Browse all 65136

Residual plot after logistic regression. What is wrong?

$
0
0
Dear all,
I am running a logistic regression and want to check for influential observations. To do that, I plot the standardized residuals for each paricipant. The plot seems a little strange, since one would expect the residuals to be in one cluster around y=0. Does anyone have any suggestions to why I get a plot like the one below (in the lower cluster, none of the observations have outcome = 0, whereas in the upper cluster, there are both outcomes = 0 and =1)?

Code:
predict stdres, rstandard
scatter stdres PREG_ID_1569
Array


Code:
logistic overweight c.noise##i.gender age_7y i.urbanity logincome i.education i.ethnicity i.emotional_7år dietscore_7y i.physact i.mat_smoke bmi_birth i.divorced if birthweight>2500 & zbfa_7år > -5 & zbfa_7år<5 & bmi_birth<25
Output (Norwegian variable names):
Code:
Logistic regression                             Number of obs     =      1,484
                                                LR chi2(19)       =      38.87
                                                Prob > chi2       =     0.0046
Log likelihood = -581.96559                     Pseudo R2         =     0.0323
 overvekt | Odds Ratio   Std. Err.      z    P>|z|     [95% Conf. Interval]

--------------------------------------------------------------------------------------------------
                        overvekt | Odds Ratio   Std. Err.      z    P>|z|     [95% Conf. Interval]
---------------------------------+----------------------------------------------------------------
        Len_vei_7åringer_livstid |   1.005131   .0137301     0.37   0.708     .9785777    1.032405
                                 |
                           KJONN |
                           Pike  |   2.371608   2.357581     0.87   0.385     .3379681    16.64217
                                 |
KJONN#c.Len_vei_7åringer_livstid |
                           Pike  |   .9743111   .0196758    -1.29   0.198     .9365005    1.013648
                                 |
                         age_7år |   1.000184   .0019205     0.10   0.923     .9964275    1.003956
                                 |
          sone_siste_adresse_7år |
             Mellom Ring 2 og 3  |   1.137747   .2134702     0.69   0.492     .7876593    1.643435
                Innenfor Ring 2  |   1.304274   .3594635     0.96   0.335     .7599305    2.238533
                                 |
                      loginntekt |   1.173329   .4466114     0.42   0.675     .5564443    2.474104
                                 |
              mors_utdanning_num |
     Univ./høyskole inntil 4 år  |   1.414774   .2347284     2.09   0.037     1.022027    1.958448
  Inntil videregående påbygning  |   1.875568   .4195352     2.81   0.005     1.209852    2.907591
                                 |
                  landbakgr_barn |
                   Ikke-vestlig  |   1.509217   .3477814     1.79   0.074     .9607323    2.370834
                                 |
                   emotional_7år |
             Vansker siste året  |   1.205125   .3618195     0.62   0.534     .6690715     2.17066
                    dietscore_7y |   .9987875   .0417213    -0.03   0.977     .9202731       1.084
                                 |
                      fysakt_7år |
                      3-7 t/uke  |   1.258417   .2436777     1.19   0.235     .8609925    1.839288
           Mindre enn 1-2 t/uke  |   1.102782   .2616349     0.41   0.680      .692695    1.755646
                                 |
                    røyk_mor_7år |
                             Ja  |   1.511349    .364988     1.71   0.087     .9414586     2.42621
                       bmi_birth |   1.142935   .0669046     2.28   0.022     1.019047    1.281884
                                 |
                       skilt_7år |
            Foreldre bor sammen  |   1.202277   .2949885     0.75   0.453     .7432853    1.944706
                           _cons |   .0032108   .0179463    -1.03   0.304     5.61e-08    183.7438
--------------------------------------------------------------------------------------------------

Best,

Kjell Weyde

Viewing all articles
Browse latest Browse all 65136

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>