+ All Categories
Home > Documents > ANALYSIS OF VARIANCE (ONE WAY)

ANALYSIS OF VARIANCE (ONE WAY)

Date post: 14-Feb-2016
Category:
Upload: kaori
View: 41 times
Download: 5 times
Share this document with a friend
Description:
Chapter 8. ANALYSIS OF VARIANCE (ONE WAY). Learning Objectives. In this chapter you will learn how to analyze between more than two groups of subjects - PowerPoint PPT Presentation
Popular Tags:
22
ANALYSIS OF ANALYSIS OF VARIANCE (ONE WAY) VARIANCE (ONE WAY) Chapter 8
Transcript
Page 1: ANALYSIS OF VARIANCE (ONE WAY)

ANALYSIS OF ANALYSIS OF VARIANCE (ONE WAY)VARIANCE (ONE WAY)

Chapter 8

Page 2: ANALYSIS OF VARIANCE (ONE WAY)

Learning ObjectivesLearning Objectives In this chapter you will learn how to In this chapter you will learn how to

analyze between more than two analyze between more than two groups of subjects groups of subjects

Analysis of variance (ANOVA) is a Analysis of variance (ANOVA) is a statistical test that is designed to statistical test that is designed to examine means across more than examine means across more than two groups by comparing variances, two groups by comparing variances, based upon the variability in each based upon the variability in each sample and in the combined samplessample and in the combined samples

Page 3: ANALYSIS OF VARIANCE (ONE WAY)

SOURCE OF ANOVASOURCE OF ANOVA With ANOVA there is no limit to the With ANOVA there is no limit to the

amount of groups that can be comparedamount of groups that can be compared When there are three or more levels for When there are three or more levels for

the nominal (grouping) variable the the nominal (grouping) variable the number of comparisons increases with number of comparisons increases with the number of groups. Therefore having the number of groups. Therefore having using multiple t-tests would be required using multiple t-tests would be required for all comparisons two at a time, the for all comparisons two at a time, the results would be very difficult to results would be very difficult to interpret.interpret.

Page 4: ANALYSIS OF VARIANCE (ONE WAY)

SOUCRE OF ANOVASOUCRE OF ANOVA ANOVA reports the variance within the ANOVA reports the variance within the

groups, ANOVA then calculates how that groups, ANOVA then calculates how that variation would translate into differences variation would translate into differences between the groups while taking into between the groups while taking into account how many groups there areaccount how many groups there are

In your data set the region is a grouping In your data set the region is a grouping variable, and use the number of prisoners variable, and use the number of prisoners executed between 1975-1995 as the executed between 1975-1995 as the independent variable independent variable

We see that the mean number of prisoners We see that the mean number of prisoners executed varies across the regions over executed varies across the regions over the time period the time period

Page 5: ANALYSIS OF VARIANCE (ONE WAY)

SOURCE OF ANOVASOURCE OF ANOVA Under ANOVA the null hypothesis is that the Under ANOVA the null hypothesis is that the

means for all the group (regions) are equalmeans for all the group (regions) are equal The null hypothesis is that there is no The null hypothesis is that there is no

difference in the average number of difference in the average number of inmates executed between 1976 and 1995 inmates executed between 1976 and 1995 across the four regions of the countryacross the four regions of the country

ANOVA tests to see which region ANOVA tests to see which region (independent variable) is producing the (independent variable) is producing the effect, that at least one of the group means effect, that at least one of the group means is different from the otheris different from the other

Page 6: ANALYSIS OF VARIANCE (ONE WAY)

SOURCES OF ANOVASOURCES OF ANOVA When scores are divided into three or When scores are divided into three or

more groups the variation can be more groups the variation can be divided into two parts:divided into two parts:

– 1. The variation of scores 1. The variation of scores within the groupswithin the groups. . Variance and standard deviationVariance and standard deviation

– 2. The variation of scores 2. The variation of scores between the groupsbetween the groups. . There is variation from one group to the next. It There is variation from one group to the next. It accounts for the variability of the means between accounts for the variability of the means between each sampleeach sample

Page 7: ANALYSIS OF VARIANCE (ONE WAY)

SOURCES OF ANOVASOURCES OF ANOVA ANOVA compares these two estimates of variabilityANOVA compares these two estimates of variability The main function of ANOVA involves whether the The main function of ANOVA involves whether the

between-groups variance is significantly larger between-groups variance is significantly larger than the within-groups variance. than the within-groups variance.

If we show that the variance of between-groups is If we show that the variance of between-groups is larger than the variance of the within-groups then larger than the variance of the within-groups then we reject the null hypothesiswe reject the null hypothesis

If the means of the groups are equal then they will If the means of the groups are equal then they will vary little around the total mean ( ) across the vary little around the total mean ( ) across the groups, if the group means are different they will groups, if the group means are different they will vary significantly around ( ) more than they vary vary significantly around ( ) more than they vary within their groupswithin their groups

Page 8: ANALYSIS OF VARIANCE (ONE WAY)

SOURCES OF ANOVASOURCES OF ANOVA ANOVA tests the null hypothesis by ANOVA tests the null hypothesis by

comparing the variation between the comparing the variation between the groups to that within the groups.groups to that within the groups.

To compute ANOVA you:To compute ANOVA you:– 1. The total amount of variation among all 1. The total amount of variation among all

scores combined (total sum of squares – SSscores combined (total sum of squares – SStt

– 2. The amount of variation between the groups 2. The amount of variation between the groups (between-groups sum of squares – SS(between-groups sum of squares – SSbb

– 3. The amount of variation within the groups 3. The amount of variation within the groups (within-groups sum of squares SS(within-groups sum of squares SSww))

Page 9: ANALYSIS OF VARIANCE (ONE WAY)

THE F TEST (F RATIO)THE F TEST (F RATIO) The ‘F’ test is a ratio of the two estimates of The ‘F’ test is a ratio of the two estimates of

variability (between-groups mean square divided variability (between-groups mean square divided by the within-groups mean square variation)by the within-groups mean square variation)

If null hypothesis is true then ‘F’ ratio value is If null hypothesis is true then ‘F’ ratio value is one, if null hypothesis is false then ‘F’ ratio is one, if null hypothesis is false then ‘F’ ratio is value is greater than onevalue is greater than one

If the ‘F’ test value is statistically significant then If the ‘F’ test value is statistically significant then you reject the null hypothesis, hence the group you reject the null hypothesis, hence the group means are not equalmeans are not equal

You can look at he group means to tell this, but You can look at he group means to tell this, but inspection does not revel where the differences inspection does not revel where the differences leading to the ‘F’ value and the rejection of null leading to the ‘F’ value and the rejection of null hypothesis originateshypothesis originates

Page 10: ANALYSIS OF VARIANCE (ONE WAY)

The F Test (F Ratio)The F Test (F Ratio) To locate the source of the difference you To locate the source of the difference you

must use a multiple comparison procedure, must use a multiple comparison procedure, the Bonferroni (discussed latter) procedure the Bonferroni (discussed latter) procedure is recommended. This test allows you to is recommended. This test allows you to pinpoint where the difference originatepinpoint where the difference originate

In our example we have four groups, thus In our example we have four groups, thus eight possible comparisons, the Bonferroni eight possible comparisons, the Bonferroni procedure pinpoints where the differences procedure pinpoints where the differences come from, protecting you from concluding come from, protecting you from concluding that too many of the differences between that too many of the differences between the group means are statistically significant. the group means are statistically significant.

Page 11: ANALYSIS OF VARIANCE (ONE WAY)

The ‘F’ Test (F ratio)The ‘F’ Test (F ratio) ANOVA Requirements:ANOVA Requirements:

– The data must be a random sample from a The data must be a random sample from a populationpopulation

– The single dependent variable must be measured The single dependent variable must be measured at the interval level ( in order to compute a mean)at the interval level ( in order to compute a mean)

– The independent variable need only to be The independent variable need only to be measured categorically at either the nominal or measured categorically at either the nominal or ordinal level (to provide group means)ordinal level (to provide group means)

Page 12: ANALYSIS OF VARIANCE (ONE WAY)

ANOVA and SPSSANOVA and SPSS Calculating ANOVA by hand is nearly impossible by Calculating ANOVA by hand is nearly impossible by

hand with large groups, yet the example in the book hand with large groups, yet the example in the book shows where the numbers that SPSS generates come shows where the numbers that SPSS generates come fromfrom

Using SPSS, we are going to compare the average Using SPSS, we are going to compare the average number of inmates executed across the four regions number of inmates executed across the four regions of the United States to see if different categories of of the United States to see if different categories of states (region is measured at the nominal level) vary states (region is measured at the nominal level) vary significantly in the mean number of prisoners significantly in the mean number of prisoners executed (a ratio level variable) over this time period executed (a ratio level variable) over this time period (1977-1995). The independent variable is the (1977-1995). The independent variable is the grouping of the regions, and the dependant variable grouping of the regions, and the dependant variable is number of prisoners executed between 1977-is number of prisoners executed between 1977-1995. 1995.

Page 13: ANALYSIS OF VARIANCE (ONE WAY)

SPSS, One way ANOVASPSS, One way ANOVA To obtain your SPSS output for ANOVA follow the steps To obtain your SPSS output for ANOVA follow the steps

outlined here.outlined here. 1.Open the existing file, “StateData.sav” figure 8.1. This is the 1.Open the existing file, “StateData.sav” figure 8.1. This is the

state data set containing crime and other data from the criminal state data set containing crime and other data from the criminal justice system for all fifty statesjustice system for all fifty states

2. Choose “Analyze”, “Compare means,” and then “One-Way 2. Choose “Analyze”, “Compare means,” and then “One-Way ANOVA” figure 8.2ANOVA” figure 8.2

3. In the “One-Way ANOVA” window (Figure 8.3) Select and enter 3. In the “One-Way ANOVA” window (Figure 8.3) Select and enter the dependent variable – “Prisoners Executed between 1977-1995” the dependent variable – “Prisoners Executed between 1977-1995” – in the “Dependant List” box. The program will calculate the mean – in the “Dependant List” box. The program will calculate the mean and other statistics for this variable. Select and enter the and other statistics for this variable. Select and enter the independent variable- “Region” in the “Factor” box. This variable independent variable- “Region” in the “Factor” box. This variable divided the sample into groupsdivided the sample into groups

4. Returning to the One-Way ANOVA window (Figure 8.4), click on 4. Returning to the One-Way ANOVA window (Figure 8.4), click on the “Options” button to open the One-Way ANOVA: Options the “Options” button to open the One-Way ANOVA: Options window. Under statistics check “Descriptive.” Click on “Continue” window. Under statistics check “Descriptive.” Click on “Continue” to return to the One way ANOVA window.to return to the One way ANOVA window.

5. Click on “Post Hoc.” Select the “Bonferroni” method (Figure 8.5). 5. Click on “Post Hoc.” Select the “Bonferroni” method (Figure 8.5). Click on “Continue” to return to the One-Way ANOVA window.Click on “Continue” to return to the One-Way ANOVA window.

6. Click on “Ok” to generate your output.6. Click on “Ok” to generate your output.

Page 14: ANALYSIS OF VARIANCE (ONE WAY)

SPSS & One Way ANOVASPSS & One Way ANOVA In this example we selected “Prisoners In this example we selected “Prisoners

Executed between 1977-1995 as the Executed between 1977-1995 as the independent variable.independent variable.

The null hypothesis is that there is no The null hypothesis is that there is no regional difference in the average number of regional difference in the average number of prisoners executed between 1977 and 1995. prisoners executed between 1977 and 1995.

The research hypothesis is that the South The research hypothesis is that the South has the highest average number of prisoners has the highest average number of prisoners executed during the this time period. executed during the this time period.

Page 15: ANALYSIS OF VARIANCE (ONE WAY)

ResultsResults The ANOVA table from 8.1 is what we The ANOVA table from 8.1 is what we

need to focus on, because we are need to focus on, because we are focusing on the null hypothesis (that focusing on the null hypothesis (that there is no difference in the average there is no difference in the average number of executions across the number of executions across the regions during the this time period). regions during the this time period). Thus we must make the decision to Thus we must make the decision to accept or reject the null hypothesis. accept or reject the null hypothesis.

Page 16: ANALYSIS OF VARIANCE (ONE WAY)

ResultsResults The first column in ANOVA gives us the sum The first column in ANOVA gives us the sum

of squares between and within the groups of squares between and within the groups and for the entire sample. The total sum of and for the entire sample. The total sum of squares represents the entire variance on squares represents the entire variance on the dependent variable for the entire sample. the dependent variable for the entire sample.

The second column represents the degrees The second column represents the degrees of freedom, (n-1). The total degrees of of freedom, (n-1). The total degrees of freedom represent 50-1=49, degrees of freedom represent 50-1=49, degrees of freedom between groups equals the number freedom between groups equals the number of groups minus one (4-1=3). The within of groups minus one (4-1=3). The within groups degrees of freedom equals 49-3=46. groups degrees of freedom equals 49-3=46.

Page 17: ANALYSIS OF VARIANCE (ONE WAY)

ResultsResults The third (mean square) column in The third (mean square) column in

figure 8.1 contains the estimates of figure 8.1 contains the estimates of variability between and within the variability between and within the groups. The mean square estimate is groups. The mean square estimate is equal to the sum of the squares equal to the sum of the squares divided by the degrees of freedom. divided by the degrees of freedom.

The between the groups mean square The between the groups mean square is 2469.194/3=823.065, the within-is 2469.194/3=823.065, the within-groups mean square is groups mean square is 10260.426/46=223.05310260.426/46=223.053

Page 18: ANALYSIS OF VARIANCE (ONE WAY)

ResultsResults The fourth column, the F ratio, is calculated The fourth column, the F ratio, is calculated

by dividing the mean square between groups by dividing the mean square between groups by the mean square within the groups.by the mean square within the groups.

If the null hypothesis is true, both mean If the null hypothesis is true, both mean square estimates should be equal and the F square estimates should be equal and the F ratio should be one, the larger the F ratio the ratio should be one, the larger the F ratio the greater the likelihood that he difference greater the likelihood that he difference between the means does not result from between the means does not result from chance. In our example the F ratio is 3.69 chance. In our example the F ratio is 3.69 (823.065/223.053).(823.065/223.053).

Page 19: ANALYSIS OF VARIANCE (ONE WAY)

ResultsResults The last column in figure 8.1 is the The last column in figure 8.1 is the

Significance level or Sig., and it tells us that Significance level or Sig., and it tells us that the value of our F ratio (3.69) is large enough the value of our F ratio (3.69) is large enough to reject the null hypothesis. The Sig. level to reject the null hypothesis. The Sig. level is .018 is less than .05. The mean number of is .018 is less than .05. The mean number of executions in the different regions of the executions in the different regions of the country between 1977-1995 were country between 1977-1995 were significantly different, and this difference is significantly different, and this difference is greater than we would expect by chance. We greater than we would expect by chance. We still can not say where the differences lie.still can not say where the differences lie.

Page 20: ANALYSIS OF VARIANCE (ONE WAY)

Bonferroni ProcedureBonferroni Procedure The Bonferroni comes into play here The Bonferroni comes into play here

(Post Hoc Tests). It adjusts the observed (Post Hoc Tests). It adjusts the observed significance level by multiplying it by the significance level by multiplying it by the number of comparisons being made, number of comparisons being made, since we are looking at eight possible since we are looking at eight possible comparisons of group means the comparisons of group means the observed sig. level must be 0.05/8 or observed sig. level must be 0.05/8 or 0.004 for the difference between group 0.004 for the difference between group means to be significant at the 0.05 level.means to be significant at the 0.05 level.

Page 21: ANALYSIS OF VARIANCE (ONE WAY)

Bonferroni ProcedureBonferroni Procedure The multiple comparison procedures protect you The multiple comparison procedures protect you

from calling differences significant when they are from calling differences significant when they are not, the more comparisons you make the larger not, the more comparisons you make the larger the difference between pairs of means must be the difference between pairs of means must be for a multiple comparison procedure to call it for a multiple comparison procedure to call it statistically significant.statistically significant.

The multiple comparisons table, table 8.1 gives The multiple comparisons table, table 8.1 gives us all possible combinations here. Each block us all possible combinations here. Each block represents one region compared to all the others represents one region compared to all the others by row. We see that the mean number of by row. We see that the mean number of executions in southern states compared against executions in southern states compared against the western states is statistically significant at the western states is statistically significant at 0.05 or less. 0.05 or less.

Page 22: ANALYSIS OF VARIANCE (ONE WAY)

ConclusionConclusion ANOVA is a statistical technique that compares the ANOVA is a statistical technique that compares the

difference between sample means when you have more difference between sample means when you have more than two samples or groups. We are analyzing the variance than two samples or groups. We are analyzing the variance within and between the samples to determine the within and between the samples to determine the significance of any differencessignificance of any differences

The F ratio between the mean squares between the groups The F ratio between the mean squares between the groups (MS(MSbb) and the mean squares within the groups (MS) and the mean squares within the groups (MSww) is the ) is the heart of ANOVA. If the null hypothesis is rejected from the F heart of ANOVA. If the null hypothesis is rejected from the F test there is a statistically significant difference between test there is a statistically significant difference between the means of the groups. In order to determine where the the means of the groups. In order to determine where the significant difference lies, the Bonferroni multiple significant difference lies, the Bonferroni multiple comparison method must be used. This test tells you which comparison method must be used. This test tells you which of the multiple comparisons between groups is statistically of the multiple comparisons between groups is statistically significantsignificant


Recommended