Analysis of variance (2) Lecture 10. Normality Check Frequency histogram (Skewness & Kurtosis) Probability plot, K-S test Normality Check Frequency histogram.

Slides:



Advertisements
Similar presentations
Quntative Data Analysis SPSS Exploring Assumptions
Advertisements

Prepared by Lloyd R. Jaisingh
Randomized Complete Block and Repeated Measures (Each Subject Receives Each Treatment) Designs KNNL – Chapters 21,
Kruskal Wallis and the Friedman Test.
© 2011 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part, except for use as permitted in a license.
Chapter Fourteen The Two-Way Analysis of Variance.
Design of Experiments and Analysis of Variance
PSY 307 – Statistics for the Behavioral Sciences Chapter 20 – Tests for Ranked Data, Choosing Statistical Tests.
Nonparametric tests and ANOVAs: What you need to know.
N-way ANOVA. Two-factor ANOVA with equal replications Experimental design: 2  2 (or 2 2 ) factorial with n = 5 replicate Total number of observations:
© 2010 Pearson Prentice Hall. All rights reserved The Complete Randomized Block Design.
1 Multifactor ANOVA. 2 What We Will Learn Two-factor ANOVA K ij =1 Two-factor ANOVA K ij =1 –Interaction –Tukey’s with multiple comparisons –Concept of.
Analysis of Variance. Experimental Design u Investigator controls one or more independent variables –Called treatment variables or factors –Contain two.
Chapter Topics The Completely Randomized Model: One-Factor Analysis of Variance F-Test for Difference in c Means The Tukey-Kramer Procedure ANOVA Assumptions.
Test statistic: Group Comparison Jobayer Hossain Larry Holmes, Jr Research Statistics, Lecture 5 October 30,2008.
Final Review Session.
Chapter 14 Conducting & Reading Research Baumgartner et al Chapter 14 Inferential Data Analysis.
Experimental Design Terminology  An Experimental Unit is the entity on which measurement or an observation is made. For example, subjects are experimental.
Analysis of variance (3). Normality Check Frequency histogram (Skewness & Kurtosis) Probability plot, K-S test Normality Check Frequency histogram (Skewness.
Chi-Square and F Distributions Chapter 11 Understandable Statistics Ninth Edition By Brase and Brase Prepared by Yixun Shi Bloomsburg University of Pennsylvania.
Analysis of Variance & Multivariate Analysis of Variance
PSY 307 – Statistics for the Behavioral Sciences Chapter 19 – Chi-Square Test for Qualitative Data Chapter 21 – Deciding Which Test to Use.
One-Way ANOVA Independent Samples. Basic Design Grouping variable with 2 or more levels Continuous dependent/criterion variable H  :  1 =  2 =... =
Non-parametric statistics
Two-Way Analysis of Variance STAT E-150 Statistical Methods.
Chapter 12 Inferential Statistics Gay, Mills, and Airasian
Inferential Statistics
Chapter 12: Analysis of Variance
ANALYSIS OF VARIANCE. Analysis of variance ◦ A One-way Analysis Of Variance Is A Way To Test The Equality Of Three Or More Means At One Time By Using.
Inferential Statistics: SPSS
Comparing Two Samples: Part I. Normality Check Frequency histogram (Skewness & Kurtosis) Probability plot, K-S test Normality Check Frequency histogram.
SPSS Series 1: ANOVA and Factorial ANOVA
Copyright © 2013, 2010 and 2007 Pearson Education, Inc. Chapter Comparing Three or More Means 13.
© 2003 Prentice-Hall, Inc.Chap 11-1 Analysis of Variance IE 340/440 PROCESS IMPROVEMENT THROUGH PLANNED EXPERIMENTATION Dr. Xueping Li University of Tennessee.
Choosing and using statistics to test ecological hypotheses
© 2002 Prentice-Hall, Inc.Chap 9-1 Statistics for Managers Using Microsoft Excel 3 rd Edition Chapter 9 Analysis of Variance.
Chapter 11 HYPOTHESIS TESTING USING THE ONE-WAY ANALYSIS OF VARIANCE.
Comparing Several Means: One-way ANOVA Lesson 15.
A Repertoire of Hypothesis Tests  z-test – for use with normal distributions and large samples.  t-test – for use with small samples and when the pop.
TAUCHI – Tampere Unit for Computer-Human Interaction ERIT 2015: Data analysis and interpretation (1 & 2) Hanna Venesvirta Tampere Unit for Computer-Human.
Psychology 301 Chapters & Differences Between Two Means Introduction to Analysis of Variance Multiple Comparisons.
Copyright © 2013 Pearson Education, Inc. All rights reserved Chapter 10 Analysis of Variance Comparing More than Two Means.
Running Scheffe’s Multiple Comparison Test in Excel
Parametric tests (independent t- test and paired t-test & ANOVA) Dr. Omar Al Jadaan.
Social Science Research Design and Statistics, 2/e Alfred P. Rovai, Jason D. Baker, and Michael K. Ponton Within Subjects Analysis of Variance PowerPoint.
ANOVA: Analysis of Variance.
Chapter 13 CHI-SQUARE AND NONPARAMETRIC PROCEDURES.
Chapter 8 1-Way Analysis of Variance - Completely Randomized Design.
Hypothesis Testing. Why do we need it? – simply, we are looking for something – a statistical measure - that will allow us to conclude there is truly.
ETM U 1 Analysis of Variance (ANOVA) Suppose we want to compare more than two means? For example, suppose a manufacturer of paper used for grocery.
Friedman F r TestThe Friedman F r Test is the nonparametric equivalent of the randomized block design with k treatments and b blocks. All k measurements.
Author(s): Brenda Gunderson, Ph.D., 2011 License: Unless otherwise noted, this material is made available under the terms of the Creative Commons Attribution–Non-commercial–Share.
Comparing k > 2 Groups - Numeric Responses Extension of Methods used to Compare 2 Groups Parallel Groups and Crossover Designs Normal and non-normal data.
Chapter 21prepared by Elizabeth Bauer, Ph.D. 1 Ranking Data –Sometimes your data is ordinal level –We can put people in order and assign them ranks Common.
Chapter Fifteen Chi-Square and Other Nonparametric Procedures.
Analysis of variance Tron Anders Moger
Chapters Way Analysis of Variance - Completely Randomized Design.
Comparing I > 2 Groups - Numeric Responses Extension of Methods used to Compare 2 Groups Independent and Dependent Samples Normal and non-normal data structures.
Session 9: k Samples (Zar, Chapter 10). (1) General Setup: Group 1Group 2…Group k x 11 x 21 x k1 x 12 x 22 x k2 x 13 x 23 x k3 x 1n 1 x 2n 2 x kn k H.
ENGR 610 Applied Statistics Fall Week 8 Marshall University CITE Jack Smith.
Educational Research Inferential Statistics Chapter th Chapter 12- 8th Gay and Airasian.
Nonparametric statistics. Four levels of measurement Nominal Ordinal Interval Ratio  Nominal: the lowest level  Ordinal  Interval  Ratio: the highest.
Statistics for Education Research Lecture 4 Tests on Two Means: Types and Paired-Sample T-tests Instructor: Dr. Tung-hsien He
Analyze Of VAriance. Application fields ◦ Comparing means for more than two independent samples = examining relationship between categorical->metric variables.
Factorial Experiments
Comparing Three or More Means
Analysis of Data Graphics Quantitative data
Exercise 1 Use Transform  Compute variable to calculate weight lost by each person Calculate the overall mean weight lost Calculate the means and standard.
STATISTICS INFORMED DECISIONS USING DATA
Presentation transcript:

Analysis of variance (2) Lecture 10

Normality Check Frequency histogram (Skewness & Kurtosis) Probability plot, K-S test Normality Check Frequency histogram (Skewness & Kurtosis) Probability plot, K-S test Descriptive statistics Measurements (data) Measurements (data) Mean, SD, SEM, 95% confidence interval YES Check the Homogeneity of Variance Data transformation NO Data transformation NO Median, range, Q1 and Q3 Non-Parametric Test(s) For 2 samples: Mann- Whitney For 2-paired samples: Wilcoxon For >2 samples: Kruskal-Wallis Sheirer-Ray-Hare Non-Parametric Test(s) For 2 samples: Mann- Whitney For 2-paired samples: Wilcoxon For >2 samples: Kruskal-Wallis Sheirer-Ray-Hare Parametric Tests Student’s t tests for 2 samples; ANOVA for  2 samples; post hoc tests for multiple comparison of means Parametric Tests Student’s t tests for 2 samples; ANOVA for  2 samples; post hoc tests for multiple comparison of means YES One-way ANOVA Tukey’s test Two-way ANOVA F max test K-W test, Dunn’s test

Kruskal-Wallis test with tied ranks Example (Zar, 1999) – comparison of pH among 4 ponds N = = 31 H = {12/[N(N + 1)]}  (R i 2 /n i ) - 3(N + 1) H = {12/[31(31 + 1)]} (8917.8) - 3(31 + 1) = Number of groups of tied ranks = m = 7  T =  (t i 3 - t i ) = ( ) + ( ) + ( ) + ( ) + ( ) + ( ) + ( ) = 168 C = 1 -  T / (N 3 - N) = 1 - (168/ ( )) = H c = H/C = / = = k - 1 = 4 -1 = 3  , 3 = < , 0.005< p <0.01, hence reject Ho (Table B1)

Dunn’s test is a non-parametric test and is used to compare any significant different means or medians. Using Example 10.11:  T = 168 For n A = 8 and n B = 8, SE =  {[(N(N + 1)/12) –  T /(12(N – 1)][(1/n A ) + (1/n B )]} SE =  {[(31(32)/12) – 168 /(12(31 – 1)][(1/8) + (1/8)]} = 4.53 For n A = 7 and n B = 8, SE =  {[(31(32)/12) – 168 /(12(31 – 1)][(1/7) + (1/8)]} = 4.69 Sample ranked by mean rank: Rank sum: Sample sizes:8887 Mean ranks: Nonparametric multiple comparisons: Dunn’s test (e.g , Zar 1999) In conclusion, water pH is the same in ponds 4 & 3 but is different in pond 1, and the relationship of pond 2 to the others is unclear. (see Table B15 for critical Q values) Similar to Tukey’s test

Normality Check Frequency histogram (Skewness & Kurtosis) Probability plot, K-S test Normality Check Frequency histogram (Skewness & Kurtosis) Probability plot, K-S test Descriptive statistics Measurements (data) Measurements (data) Mean, SD, SEM, 95% confidence interval YES Check the Homogeneity of Variance Data transformation NO Data transformation NO Median, range, Q1 and Q3 Non-Parametric Test(s) For 2 samples: Mann- Whitney For 2-paired samples: Wilcoxon For >2 samples: Kruskal-Wallis Sheirer-Ray-Hare Non-Parametric Test(s) For 2 samples: Mann- Whitney For 2-paired samples: Wilcoxon For >2 samples: Kruskal-Wallis Sheirer-Ray-Hare Parametric Tests Student’s t tests for 2 samples; ANOVA for  2 samples; post hoc tests for multiple comparison of means Parametric Tests Student’s t tests for 2 samples; ANOVA for  2 samples; post hoc tests for multiple comparison of means YES One-way ANOVA Tukey’s test Two-way ANOVA F max test K-W test, Dunn’s test Friedman Next lecture Other ANOVAs

Two-factor ANOVA 2-way ANOVA Can simultaneously assess the effects of two factors on a variable. Can also test for interaction among factors, provided that data in each cell of a contingency table consist observations n > 1. Assumption: normal data with equal variances but ANOVA is robust (see p , Zar 1999)

2-way ANOVA with equal replication Example 12.1: The effects of sex and hormone treatment on plasma calcium concentrations (in mg/100 ml) of birds. Questions: Is there a significant difference between the mean calcium concentration of males and females? Is there a significant difference between the mean calcium concentration in each treatment (control vs. hormone treatment)?

Mean & 95% C.I.

Mean and 95% C.I. Two factors -Sex -Hormone F-Test Two-Sample for Variances Variable 1Variable 2 Mean Variance Observations55 df44 F P(F<=f) one-tail F Critical one-tail Passed the Fmax test, indicating equal variances among the four means

SS total = SS within cells + SS between A + SS between B + SS interaction SS within cells = SS total – SS cells SS interaction = SS cells – SS between A – SS between B DF total = N – 1 DF cells (explained) = (n A )(n B ) – 1 DF within cells (residual or error) = (n A )(n B )(n’ – 1) where n’= no. of replicates within each cell DF between A = n A – 1 DF between B = n B – 1 DF A  B interaction = (DF between A )(DF between B )

SS total = – (436.5) 2 /20 = DF total = 20 – 1 = 19 SS cells = [(74.4) 2 + (60.6) 2 + (162.6) 2 + (138.9) 2 ]/5 - (436.5) 2 /20 = DF cells = (2)(2) - 1 = 3 SS within cells = SS total - SS cells = – = DF within cells = (2)(2)(5 – 1) = 16

SS total = – (436.5) 2 /20 = DF total = 20 – 1 = 19 SS cells = [(74.4) 2 + (60.6) 2 + (162.6) 2 + (138.9) 2 ]/5 - (436.5) 2 /20 = DF cells = (2)(2) - 1 = 3 SS within cells = – = DF within cells = (2)(2)(5 – 1) = 16 SS between treatments = {[(135.0) 2 + (301.5) 2 ] /(2)(5)} - (436.5) 2 /20 = DF between treatment = = 1 SS between sexes = {[(237.0) 2 + (199.5) 2 ] /(2)(5)} - (436.5) 2 /20 = DF between sexes = = 1 SS interaction = SS cells – SS between A – SS between B = – – = DF interaction = (1)(1) = 1 Equations: See p. 242 (Zar, 1999)

Analysis of Variance Summary Table There was a significant effect of hormone treatment on plasma calcium concentrations in the birds (P <0.001). There was no interaction between sex and hormone treatment while the sex effect was not significant (likely due to inadequate power) Tukey test same as 1-way ANOVA

ANOVA Source of VariationSSdfMSFP-valueF crit Sample < Columns Interaction Within Total Output from Excel

[Ca] female male [Ca] control hormone treated control hormone treated [Ca] control hormone treated [Ca] control hormone treated Sex  Horm.  Sex X Horm.  Sex X Horm. X Sex  Horm. X

[Ca] female male [Ca] control hormone treated control hormone treated [Ca] control hormone treated [Ca] control hormone treated Sex  Horm.  Sex  Horm.  Intera.  Sex  Horm.  Intera.  Sex  Horm.  Intera. 

Interactive effects between variables: (a) no interaction; (b) interaction. (a) (b)

An example: The effects of light and sex on food intake in starlings. Total food intake (g) for 7 days

An example: The effects of light and sex on food intake in starlings. Two sexes have different food intake levels (p < 0.001). A significant interaction (p <0.05) indicates that two sexes respond significantly differently to day- length in the amount of food they eat.

Computation of the F statistics for tests of significance in 2- way ANOVA with replicates

Cannot test for the interacting effect !

2-way ANOVA for data without replication Interaction cannot be measured where data in each cell of a contingency table consist of single observations. Variability due to interaction is combined with the within variability and it is assumed to be negligible.

Other two experimental design suitable for 2-way ANOVA The randomized block See Example 12.4 (Zar, 99) Each block contains 4 animals: The randomized block See Example 12.4 (Zar, 99) Each block contains 4 animals: Repeated-measures See Example 12.5 (Zar, 1999) e.g. effects of diet type on food wastage in fish farm Repeated-measures See Example 12.5 (Zar, 1999) e.g. effects of diet type on food wastage in fish farm Other example: different colours of buckets (water traps) to sample insects Equivalent non-parametric method: Friedman’s analysis of variance by ranks (see p , Zar 1999)

Use SPSS to conduct a 2-way ANOVA Column 1Column 2 Column 3 obs obs obs obs. i obs. i obs. i 23 Factor AFactor BDependent variable ……..

Normality Check Frequency histogram (Skewness & Kurtosis) Probability plot, K-S test Normality Check Frequency histogram (Skewness & Kurtosis) Probability plot, K-S test Descriptive statistics Measurements (data) Measurements (data) Mean, SD, SEM, 95% confidence interval YES Check the Homogeneity of Variance Data transformation NO Data transformation NO Median, range, Q1 and Q3 Non-Parametric Test(s) For 2 samples: Mann- Whitney For 2-paired samples: Wilcoxon For >2 samples: Kruskal-Wallis Sheirer-Ray-Hare Non-Parametric Test(s) For 2 samples: Mann- Whitney For 2-paired samples: Wilcoxon For >2 samples: Kruskal-Wallis Sheirer-Ray-Hare Parametric Tests Student’s t tests for 2 samples; ANOVA for  2 samples; post hoc tests for multiple comparison of means Parametric Tests Student’s t tests for 2 samples; ANOVA for  2 samples; post hoc tests for multiple comparison of means YES One-way ANOVA Tukey’s test Two-way ANOVA F max test K-W test, Dunn’s test Friedman Next lecture Other ANOVAs

Key notes After performing a Kruskal-Wallis test, a Dunn’s test can be used to identify any significantly different medians (or means) based on ranking Two-way ANOVA can be used to analyze samples which have been subjected to two levels of treatment In two-way ANOVA, there are several different design: (Model 1) both factors A and B are fixed factors; (Model 2) both factors are random factors; (Model 3) mixed factors. Furthermore, two-way ANOVA can also be applied to data with randomized block or repeated measure designs as well as data without replication. In two-way ANOVA, interaction cannot be tested where data in each cell of a contingency table consist of single observations.