Residual Plots SPSS

download Residual Plots SPSS

of 14

Transcript of Residual Plots SPSS

  • 8/10/2019 Residual Plots SPSS

    1/14

    Producing and Interpreting Residuals Plots in SPSS

    In a linear regression analysis it is assumed that the distribution of residuals,)( YY , is, in the population, normal at every level of predicted Y and constant in

    variance across levels of predicted Y. I shall illustrate how to check that assumption.Although I shall use a bivariate regression, the same techniue would work for amultiple regression.

    !tart by downloading Residual-Skew.datand Residual-Hetero.datfrom my!tat"ata pageand A#$%A&.sav from my !'!! data page. ach line of data has fourscores *, Y, *+, and Y+. he delimiter is a blank space.

    -reate new variable !/0Y+ this way ransform, -ompute,

    $1.

    2irst some descriptive statistics on the variables

    Descriptive Statistics

    +33 &4 56 67.89 9.978 :.38; .&5+ .&4& .;6+

    +33 ++ 55 69.44 9.765 :.349 .&5+ :.+66 .;6+

    +33 & &66 68.47 +5.&+; &.364 .&5+ &.3;7 .;6+

    +33 ; &4; 67.6; +5.676 .967 .&5+ &.+83 .;6+

    +33 &.5; &+.55 4.458& &.95+99 .&5& .&5+ :.&94 .;6+

    +33

    *

    Y

    *+Y+

    Y+0!/

    %alid # (listwise)

    !tatistic !tatistic !tatistic !tatistic !tatistic !tatistic !td. rror !tatistic !td. rror

    #

  • 8/10/2019 Residual Plots SPSS

    2/14

    +

  • 8/10/2019 Residual Plots SPSS

    3/14

    Model Summaryb

    .683a .+3; .&99 7.7&8

  • 8/10/2019 Residual Plots SPSS

    4/14

    !'!! has saved the residuals, unstandardiCed (/!0&) and standardiCed(E/0&) to the data file

    AnalyCe, =plore E/0& to get a better picture of the standardiCed residuals.

    he plots look fine. As you can see, the skewness and kurtosis of the residuals is aboutwhat you would e=pect if they came from a normal distribution

    6

  • 8/10/2019 Residual Plots SPSS

    5/14

    Descriptives

    .3333333

    :+.8867&

    +.488&7

    8.+3999

    :.356

    :.+46

  • 8/10/2019 Residual Plots SPSS

    6/14

    #otice that the residuals plots shows the residuals not to be normally distributed > theyare pulled out (skewed) towards the top of the plot. =plore also shows trouble

    4

  • 8/10/2019 Residual Plots SPSS

    7/14

    Descriptives

    .3333333

    :&.75656

    ;.4&;99

    8.6775;

    &.;63;9

    .73;

    .948

  • 8/10/2019 Residual Plots SPSS

    8/14

    Model Summaryb

    .689a .+&& .+35 &.585;7

  • 8/10/2019 Residual Plots SPSS

    9/14

    e are done with the /esidual:!kew data set now. /ead into !'!! theA#$%A&.sav data file. -onduct a linear regression analysis to predict illness from doseof drug. !ave the standardiCed residuals and obtain the same plots that we producedabove.

    Model Summaryb

    .&&3a .3&+ .33+ &+.&&;

  • 8/10/2019 Residual Plots SPSS

    10/14

    #ow predict Illness from a combination of "ose and "ose0!. Ask for the usualplots and save residuals and predicted scores.

    Model Summary(b

  • 8/10/2019 Residual Plots SPSS

    11/14

    @et us have a look at the regression line. e saved the predicted scores('/0&), so we can plot their means against dose of the drug

    -lick Fraphs, @ine, !imple, "efine.

    !elect @ine /epresents $ther statistic and scoot '/0& into the variable bo=.!coot "ose into the -ategory A=is bo=. $1.

    &&

  • 8/10/2019 Residual Plots SPSS

    12/14

    ow, that is certainly no straight line. hat we have done here is a polynomialregression, fitting the data with a uadratic line. A uadratic line can have one bend init.

    @et us get a scatter plot with the data and the uadratic regression line. -lickFraph, !catter, !imple !catter, "efine. !coot Illness into the Y:a=is bo= and "ose intothe *:a=is bo=. $1. "ouble:click the graph to open the graph editor and selectlements, 2it line at total. !'!! will draw a nearly flat, straight line. In the 'ropertiesbo= change 2it

  • 8/10/2019 Residual Plots SPSS

    13/14

    e are done with the A#$%A.sav data for now. Gring into !'!! the /esidual:?/$.dat data. ach case has two scores, * and Y. he delimiter is a blank space.-onduct a regression analysis predicting Y from *. -reate residuals plots and save thestandardiCed residuals as we have been doing with each analysis.

    &;

  • 8/10/2019 Residual Plots SPSS

    14/14

    As you can see, the residuals plot shows clear evidence of heteroscedasticity. Inthis case, the error in predicted Y increases as the value of predicted Y increases. Ihave been told that transforming one the variables sometimes reducesheteroscedasticity, but in my e=perience it often does not help.

    /eturn to uenschHs !'!! @essons 'age

    -opyright +335, 1arl @. uensch : All rights reserved.

    &6

    http://core.ecu.edu/psyc/wuenschk/SPSS/SPSS-Lessons.htmhttp://core.ecu.edu/psyc/wuenschk/SPSS/SPSS-Lessons.htm