ANOVA ANALYSIS Eighth-Grade Pupils in the Netherlands
宋汶達 孫偉傑 陳盈志 徐健豪 朱明興 第八組
Eighth-Grade Pupils in the Netherlands Description Snijders and Bosker (1999) use as a running example a study of 2287 eighth- grade pupils (aged about 11) in 132 classes in 131 schools in the Netherlands. Only the variables used in our examples are supplied. Usage nlschools Format This data frame contains 2287 rows and the following columns: lang language test score. IQ verbal IQ. class class ID. GS class size: number of eighth-grade pupils recorded in the class (there may be others: see COMB, and some may have been omitted with missing values). SES social-economic status of pupil's family. COMB were the pupils taught in a multi-grade class (0/1)? Classes which contained pupils from grades 7 and 8 are coded 1, but only eighth-graders were tested.
Levels We set IQ for 3 levels Level 1. 4~ 9.5 Level 2. 10~13.5 Level 3. 14~18 We set SES for 3 levels Level ~ 17 Level ~ 38 Level ~ 50 We set COMB for 2 levels Level 1. 0 N Level 2. 1 Y
假設 虛無假設 :IQ 對於 lang 沒有顯著差異 對立假設 :IQ 對於 lang 有顯著差異
IQ 與成績的關係圖
IQ 的 ANOVA TABLE Analysis of Variance Table Response: lang Df Sum Sq Mean Sq F value Pr(>F) IQ < 2.2e-16 *** Residuals Signif. codes: 0 ‘***’ ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
IQ 的迴歸式 Call: lm(formula = lang ~ IQ) Residuals: Min 1Q Median 3Q Max Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) <2e-16 *** IQII <2e-16 *** IQIII <2e-16 *** --- Signif. codes: 0 ‘***’ ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 Residual standard error: on 2284 degrees of freedom Multiple R-squared: , Adjusted R-squared: F-statistic: on 2 and 2284 DF, p-value: < 2.2e-16
假設 虛無假設 :SES 對於 lang 沒有顯著差異 對立假設 :SES 對於 lang 有顯著差異
SES 與成績的關係圖
SES 的 ANOVA TABLE Analysis of Variance Table Response: lang Df Sum Sq Mean Sq F value Pr(>F) SES < 2.2e-16 *** Residuals Signif. codes: 0 ‘***’ ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
SES 的迴歸式 Call: lm(formula = lang ~ SES) Residuals: Min 1Q Median 3Q Max Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) <2e-16 *** SESB <2e-16 *** SESC <2e-16 *** --- Signif. codes: 0 ‘***’ ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 Residual standard error: on 2284 degrees of freedom Multiple R-squared: , Adjusted R-squared: F-statistic: on 2 and 2284 DF, p-value: < 2.2e-16
虛無假設 :COMB 對於 lang 沒有顯著差異 對立假設 :COMB 對於 lang 有顯著差異 假設
COMB 與成績的關係圖
COMB 的 ANOVA TABLE Analysis of Variance Table Response: lang Df Sum Sq Mean Sq F value Pr(>F) COMB e-09 *** Residuals Signif. codes: 0 ‘***’ ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
COMB 的迴歸式 Call: lm(formula = lang ~ COMB) Residuals: Min 1Q Median 3Q Max Coefficients: Estimate Std. Error t value Pr(>|t|) (Intercept) < 2e-16 *** COMBY e-09 *** --- Signif. codes: 0 ‘***’ ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 Residual standard error: 8.94 on 2285 degrees of freedom Multiple R-squared: , Adjusted R-squared: F-statistic: 33.5 on 1 and 2285 DF, p-value: 8.1e-09
交互影響 虛無假設 :IQ 與 SES 的交互作用 對於 lang 沒有顯著差異 對立假設 :IQ 與 SES 對於 lang 有顯著差異 虛無假設 :IQ 與 COMB 的交互作用 對於 lang 沒有顯著差異 對立假設 :IQ 與 COMB 對於 lang 有顯著差異 虛無假設 :SES 與 COMB 的交互作用 對於 lang 沒有顯著差 異 對立假設 :SES 與 COMB 對於 lang 有顯著差異
> anova(lm(lang~IQ*SES*COMB)) Analysis of Variance Table Response: lang Df Sum Sq Mean Sq F value Pr(>F) IQ < 2.2e-16 *** SES < 2.2e-16 *** COMB e-09 *** IQ:SES IQ:COMB *** SES:COMB IQ:SES:COMB Residuals Signif. codes: 0 ‘***’ ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0--- Signif. codes: 0 ‘***’ ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0 ANOVA TABLE
IQ 與 COMB 的交互影響圖
進階分析 -1 > TukeyHSD(aov(lm(lang~IQ))) Tukey multiple comparisons of means 95% family-wise confidence level Fit: aov(formula = lm(lang ~ IQ)) $IQ diff lwr upr p adj II-I III-I III-II
進階分析 -2 > TukeyHSD(aov(lm(lang~SES))) Tukey multiple comparisons of means 95% family-wise confidence level Fit: aov(formula = lm(lang ~ SES)) $SES diff lwr upr p adj B-A C-A C-B
進階分析 -3 > TukeyHSD(aov(lm(lang~COMB))) Tukey multiple comparisons of means 95% family-wise confidence level Fit: aov(formula = lm(lang ~ COMB)) $COMB diff lwr upr p adj Y-N
Thank for your attention