class: center, middle, inverse, title-slide # Project ## 國三數學成就影響因素之多層次分析:以TEPS資料為例 ### Yi Cheng, Tung & Tang Jung, Lee ### 2020-12-21 --- ## 研究動機 ### * 教學經驗、城鄉差距 ### 國三是學生人生中面臨第一次考試升學的階段,除了一般所認知的先備知識外,學校和班級可能也是影響子女學習的重要因素,為了因應國中基測,不少家長願意跨戶籍的讓學生就讀較市區的學校。本研究旨在於探討學校與班級是否對國三時的數學表現有效果存在。 --- ## 研究問題 ### 1.探討個人層次(性別、國一剛開始的數學成就)對子女兩年後國三數學成就的影響為何? ### 2.探討班級層次(老師的教學年資) 對子女國三數學成就的影響為何? ### 3.探討學校層次(公、私立學校、學校所在地區別-鄉村、城鎮、都市)對子女國三數學成就的影響為何? ### 4.比較班級層次及學校層次對國三數學成就的隨機效果為何? --- ### 文獻探討:班級對學業成績的影響 ### 教師是建立學校的社會資本(例如建立班級規矩、學校規矩等)方面的重要人物,而教師的教學年資會影響學生的學業成績(Sawchuk, 2015) ### 以能力分班來看,就讀於部分年級有分班的學校,且於八及九年級讀資優班或只於九年級讀資優班,會對正面影響九年級學習成就(關秉寅,2016)。 --- ### 文獻探討:學校地區別(school )對學業成績的影響 ### 學區之間的學業成績差異很大,社區社會經濟地位與學業成績之間的關聯隨著就學時間越長。(Reardon, 2016) --- ## 資料介紹 ### 1.臺灣教育長期追蹤資料庫(TEPS),分別取自TEPS公開釋出之2001年第一波國中學生問卷、家長問卷和學生表現評量問卷資料及2003年第二波的國中學生問卷資料等四種資料。 ### 2.在選取有效樣本上,首先合併第一波和第二波共5份資料,選取相關的變項,在經歷過datamanagement後,刪除遺漏值,總共只剩7059個學生。 --- ## Data ```r head(dta) ``` ``` ## studid sector urban gender classtype schoolID classID mathassesment1 ## 1 1 Public town F N t009 t0489 2 ## 2 4 Public city M N t304 t0129 3 ## 3 6 Public town F G t173 t1004 3 ## 4 7 Public city F N t218 t0414 2 ## 5 8 Public city F N t136 t0930 3 ## 6 11 Public city M N t205 t1071 3 ## mathstudy1 mathwork1 mathquestion1 premath yearstea mathassesment2 mathstudy2 ## 1 2 2 1 7 15 2 3 ## 2 3 2 2 10 15 2 2 ## 3 3 1 3 10 1 2 3 ## 4 2 2 1 7 20 2 3 ## 5 3 1 1 8 20 3 3 ## 6 2 1 3 9 2 3 3 ## mathwork2 mathquestion2 mathjr3 ## 1 1 1 7 ## 2 3 1 8 ## 3 1 1 7 ## 4 1 2 8 ## 5 1 2 9 ## 6 2 3 11 ``` --- ## 分析方法 ### 本研究使用2001年第一波國中學生問卷、教師問卷和學生表現評量問卷資料及2003年第二波的國中學生問卷資料(N=7059)。 ### 三階層之多層次分析 ### 1.個人層次-(1)性別、國一剛開始的數學成就。 ### 2.班級層次-(1)教師教學年資。 ### 3.學校層次-(1)公、私立學校、(2)學校所在地區別(鄉村、城鎮、都市)。 --- ##Summary table -Individual ```r dta %>% furniture::table1(premath, mathjr3, splitby= ~ gender, test=FALSE ) ``` ``` ## ## ───────────────────────────── ## gender ## F M ## n = 3379 n = 3680 ## premath ## 8.7 (1.6) 8.7 (1.7) ## mathjr3 ## 8.5 (1.9) 8.4 (2.0) ## ───────────────────────────── ``` --- ##Summary table -teaching years ```r dta %>% furniture::table1(premath, mathjr3, splitby= ~ yearstea, test=FALSE ) ``` ``` ## ## ─────────────────────────────────────────────────────────── ## yearstea ## 1 2 8 15 20 ## n = 320 n = 978 n = 1212 n = 3353 n = 1196 ## premath ## 8.7 (1.7) 8.7 (1.7) 8.7 (1.6) 8.8 (1.7) 8.7 (1.7) ## mathjr3 ## 8.1 (1.9) 8.3 (1.9) 8.5 (1.9) 8.5 (2.0) 8.4 (2.0) ## ─────────────────────────────────────────────────────────── ``` --- ## Summary table -urban ```r dta %>% furniture::table1(premath, mathjr3, splitby= ~ urban, test=FALSE ) ``` ``` ## ## ─────────────────────────────────────── ## urban ## city town village ## n = 4052 n = 2608 n = 399 ## premath ## 8.8 (1.7) 8.7 (1.7) 8.3 (1.8) ## mathjr3 ## 8.6 (2.0) 8.3 (1.9) 8.0 (1.9) ## ─────────────────────────────────────── ``` --- ## 9th scores by school .pull-left[ ```r ggplot(data=dta, aes(x=reorder(schoolID, mathjr3, median), y=mathjr3, group=schoolID)) + geom_point(size=rel(.3), alpha=.5) + labs(y="9th score", x="School ID") + theme_minimal() + theme(axis.text.x=element_text(size=rel(.5), angle=90, hjust=1), legend.position="NONE") ``` ] .pull-right[ <!-- --> ] --- ## School 9th score means and CIs .pull-left[ ```r ggplot(data=dta, aes(x=reorder(schoolID, mathjr3, mean), y=mathjr3, group=schoolID)) + stat_summary(fun.data="mean_cl_boot", size=rel(.1))+ coord_flip()+ labs(y="9th score", x="School ID") + theme_minimal() + theme(axis.text.y=element_text(size=rel(.5), angle=0, vjust=1), legend.position="NONE") ``` ] .pull-right[ <!-- --> ] --- ## Distribution of all school averages .pull-left[ ```r sdta <- dta %>% group_by(schoolID) %>% dplyr::summarize(jr3_ave=mean(mathjr3), jr3_sd2=var(mathjr3)) ggplot(data=sdta, aes(jr3_ave)) + stat_bin(bins=grDevices::nclass.FD(sdta$jr3_ave), alpha=0.3, fill=8, col=1) + geom_vline(xintercept=mean(dta$mathjr3), linetype="dashed", col=2) + geom_vline(xintercept=mean(sdta$jr3_ave), linetype="dotted", col="purple") + labs(y="Count", x="Average score by school") + theme_minimal() ``` ] .pull-right[ <!-- --> ] --- ## Distributions of squared deviatons .pull-left[ ```r sdta <- sdta %>% mutate(dev2=(jr3_ave-mean(dta$mathjr3))^2) ggplot(data=sdta, aes(dev2)) + stat_bin(bins=grDevices::nclass.FD(sdta$dev2), alpha=0.3, fill='white', col=4) + stat_bin(aes(jr3_sd2), bins=grDevices::nclass.FD(sdta$jr3_sd2), alpha=0.3, fill=8, col=1) + labs(y="Count", x="Deviation estimates", title="within- and between-school") + theme_minimal() ``` ] .pull-right[ <!-- --> ] --- ## only School's random effects .pull-left[ ```r m0 <- lme4::lmer(mathjr3 ~ (1 | schoolID), data=dta) summary(m0) ``` The estimated mean of 9th scores is 8.42 The estimated between school variance in 9th score is 0.001. The variation between student within the same school is estimated to be 3.81 The correlation between 9th scores of student attending the same school is 0 (ICC).] .pull-right[ ``` ## Linear mixed model fit by REML ['lmerMod'] ## Formula: mathjr3 ~ (1 | schoolID) ## Data: dta ## ## REML criterion at convergence: 29476.5 ## ## Scaled residuals: ## Min 1Q Median 3Q Max ## -2.2720 -0.7296 0.2915 0.8066 3.3754 ## ## Random effects: ## Groups Name Variance Std.Dev. ## schoolID (Intercept) 0.001197 0.03459 ## Residual 3.807165 1.95120 ## Number of obs: 7059, groups: schoolID, 167 ## ## Fixed effects: ## Estimate Std. Error t value ## (Intercept) 8.4232 0.0234 360 ``` ] --- ## Centering ```r dta <- dta %>% mutate(premath_a = mean(premath)) %>% group_by(schoolID) %>% mutate(premath_sa=mean(premath) - premath_a, #各校7th平均-整體平均 premath_c=premath - mean(premath)) #各校7th-7th平均(各校) head(dta)[18:21] ``` ``` ## # A tibble: 6 x 4 ## mathjr3 premath_a premath_sa premath_c ## <int> <dbl> <dbl> <dbl> ## 1 7 8.72 0.0527 -1.77 ## 2 8 8.72 0.0214 1.26 ## 3 7 8.72 0.450 0.829 ## 4 8 8.72 -0.0944 -1.63 ## 5 9 8.72 0.167 -0.889 ## 6 11 8.72 -0.235 0.514 ``` --- ## 9th Math & 7th Math by school .pull-left[ ```r ggplot(dta, aes(premath_c, mathjr3, group=schoolID)) + geom_point(alpha=.2)+ stat_smooth(method="lm", formula=y~x, se=FALSE, size=rel(.5), col=8)+ stat_smooth(aes(x=premath_sa, y=mathjr3, group=1), method="lm", formula=y~x, se=FALSE, size=rel(.5), col=5)+ labs(x="7th score (school-centered)", y="9th score")+ theme_minimal() ``` ] .pull-right[ <!-- --> ] --- ## Add 7th score as fixed effect .pull-left[ ```r m1 <- lme4::lmer(mathjr3 ~ premath_c + (1 | schoolID), data=dta) summary(m1) ``` The estimated mean of 9th scores for all student is 8.42. For one point increase in 7th score, 9th score increase by 0.57 point, on average. ICC=0.01 About 24.93% (= 3.81−2.86/3.81) of variance in 9th scores can be attributed to differences in 7th scores among children attending different schools. ] .pull-right[ ``` ## Linear mixed model fit by REML ['lmerMod'] ## Formula: mathjr3 ~ premath_c + (1 | schoolID) ## Data: dta ## ## REML criterion at convergence: 27500.3 ## ## Scaled residuals: ## Min 1Q Median 3Q Max ## -3.8223 -0.6672 0.0080 0.6785 3.7219 ## ## Random effects: ## Groups Name Variance Std.Dev. ## schoolID (Intercept) 0.02101 0.145 ## Residual 2.85781 1.691 ## Number of obs: 7059, groups: schoolID, 167 ## ## Fixed effects: ## Estimate Std. Error t value ## (Intercept) 8.41982 0.02327 361.84 ## premath_c 0.57473 0.01199 47.93 ## ## Correlation of Fixed Effects: ## (Intr) ## premath_c 0.000 ``` ] --- ```r sjPlot::tab_model(m0, m1, show.p=FALSE, show.r2=FALSE, show.obs=FALSE, show.ngroups=FALSE, show.se=TRUE, show.ci=FALSE) ``` <table style="border-collapse:collapse; border:none;"> <tr> <th style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; text-align:left; "> </th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> </tr> <tr> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; text-align:left; ">Predictors</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">(Intercept)</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.42</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.02</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.42</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.02</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">premath_c</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.57</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.01</td> </tr> <tr> <td colspan="5" style="font-weight:bold; text-align:left; padding-top:.8em;">Random Effects</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">σ<sup>2</sup></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">3.81</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">2.86</td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">τ<sub>00</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.00 <sub>schoolID</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.02 <sub>schoolID</sub></td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">ICC</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.00</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.01</td> </table> --- ## Add gender as fixed effect .pull-left[ ```r m1g <- lme4::lmer(mathjr3 ~ gender+premath_c + (1 | schoolID), data=dta) summary(m1g) ``` when add the gender as fixed effect, the random effect only drops a little.] .pull-right[ ``` ## Linear mixed model fit by REML ['lmerMod'] ## Formula: mathjr3 ~ gender + premath_c + (1 | schoolID) ## Data: dta ## ## REML criterion at convergence: 27495.5 ## ## Scaled residuals: ## Min 1Q Median 3Q Max ## -3.7883 -0.6718 0.0075 0.6817 3.7606 ## ## Random effects: ## Groups Name Variance Std.Dev. ## schoolID (Intercept) 0.02094 0.1447 ## Residual 2.85444 1.6895 ## Number of obs: 7059, groups: schoolID, 167 ## ## Fixed effects: ## Estimate Std. Error t value ## (Intercept) 8.48438 0.03136 270.549 ## genderM -0.12378 0.04035 -3.068 ## premath_c 0.57473 0.01198 47.954 ## ## Correlation of Fixed Effects: ## (Intr) gendrM ## genderM -0.671 ## premath_c 0.000 0.000 ``` ] --- ## Including Indivisual(7thscore) and school-level predictors .pull-left[ ```r m3 <- lme4::lmer(mathjr3 ~ premath_c + premath_sa + (1 | schoolID), data=dta) sjPlot::tab_model(m0, m3, show.p=FALSE, show.r2=FALSE, show.obs=FALSE, show.ngroups=FALSE, show.se=TRUE, show.ci=FALSE,digits.re = 3) ``` premath_c and premath_sa are significant as predictions. ] .pull-right[ <table style="border-collapse:collapse; border:none;"> <tr> <th style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; text-align:left; "> </th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> </tr> <tr> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; text-align:left; ">Predictors</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">(Intercept)</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.42</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.02</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.42</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.02</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">premath_c</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.57</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.01</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">premath_sa</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.70</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.08</td> </tr> <tr> <td colspan="5" style="font-weight:bold; text-align:left; padding-top:.8em;">Random Effects</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">σ<sup>2</sup></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">3.807</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">2.850</td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">τ<sub>00</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.001 <sub>schoolID</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.000 <sub>schoolID</sub></td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">ICC</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.000</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2"> </td> </table> ] --- ## remove fixed effect, add class random effect. ####Class withins schools .pull-left[ ```r m3L0 <- lme4::lmer(mathjr3 ~ 1 + (1 | schoolID/classID), data=dta) sjPlot::tab_model(m0, m3L0, show.p=FALSE, show.r2=FALSE, show.obs=FALSE, show.ngroups=FALSE, show.se=TRUE, show.ci=FALSE , digits.re = 3) ``` Add class effect, ICC increasing a little. 9th scores of any two children from the same class within the same school has a correlation of 0.013 (= 0.005+0/3.808). 9th scores of any two children from the same school has a correlation of 0.] .pull-right[ <table style="border-collapse:collapse; border:none;"> <tr> <th style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; text-align:left; "> </th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> </tr> <tr> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; text-align:left; ">Predictors</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">(Intercept)</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.42</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.02</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.42</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.02</td> </tr> <tr> <td colspan="5" style="font-weight:bold; text-align:left; padding-top:.8em;">Random Effects</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">σ<sup>2</sup></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">3.807</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">3.803</td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">τ<sub>00</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.001 <sub>schoolID</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.005 <sub>classID:schoolID</sub></td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;"></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2"> </td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.000 <sub>schoolID</sub></td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">ICC</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.000</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.001</td> </table> ] --- ## Effect of teaching experience .pull-left[ ```r ggplot(dta, aes(yearstea, mathjr3)) + geom_point(alpha=.3)+ stat_smooth(method="lm", formula=y~x, se=FALSE, size=rel(.3), col="purple")+ labs(x="Teaching experience (in years)", y="9th score")+ theme_minimal() ``` The teacher's teaching years are not related to the student's grades.] .pull-right[ <!-- --> ] --- ## Effect of teaching experience-lmer ```r m3L1 <- lme4::lmer(mathjr3 ~ yearstea + (1 | schoolID) + (1| classID:schoolID), data=dta) sjPlot::tab_model(m3L0, m3L1, show.p=FALSE, show.r2=FALSE, show.obs=FALSE, show.ngroups=FALSE, show.se=TRUE, show.ci=FALSE, show.re.var =FALSE, show.icc = FALSE) ``` <table style="border-collapse:collapse; border:none;"> <tr> <th style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; text-align:left; "> </th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> </tr> <tr> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; text-align:left; ">Predictors</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">(Intercept)</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.42</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.02</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.33</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.05</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">yearstea</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.01</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.00</td> </tr> </table> <br/> Once again, it was verified that the teacher's teaching years had nothing to do with students grades. --- ## Effect of sector and urban-lmer ```r m3L4 <- lmer(mathjr3 ~ urban + (1 | schoolID) + (1| classID:schoolID), data=dta) m3L5 <- lmer(mathjr3 ~ urban+ sector + (1 | schoolID) + (1| classID:schoolID), data=dta) sjPlot::tab_model(m3L0, m3L4,m3L5, show.p=FALSE, show.r2=FALSE, show.obs=FALSE, show.ngroups=FALSE, show.se=TRUE, show.ci=FALSE) ``` <table style="border-collapse:collapse; border:none;"> <tr> <th style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; text-align:left; "> </th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> <th colspan="2" style="border-top: double; text-align:center; font-style:normal; font-weight:bold; padding:0.2cm; ">mathjr3</th> </tr> <tr> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; text-align:left; ">Predictors</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">std. Error</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; ">Estimates</td> <td style=" text-align:center; border-bottom:1px solid; font-style:italic; font-weight:normal; col7">std. Error</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">(Intercept)</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.42</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.02</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">8.55</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.03</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">9.03</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; col7">0.07</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">urban [town]</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">-0.26</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.05</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">-0.25</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; col7">0.05</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">urban [village]</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">-0.55</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">0.10</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">-0.48</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; col7">0.10</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; ">sector [Public]</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; "></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; ">-0.55</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:center; col7">0.07</td> </tr> <tr> <td colspan="7" style="font-weight:bold; text-align:left; padding-top:.8em;">Random Effects</td> </tr> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">σ<sup>2</sup></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">3.80</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">3.78</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">3.75</td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">τ<sub>00</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.01 <sub>classID:schoolID</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.00 <sub>classID:schoolID</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.00 <sub>classID:schoolID</sub></td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;"></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.00 <sub>schoolID</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.00 <sub>schoolID</sub></td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.00 <sub>schoolID</sub></td> <tr> <td style=" padding:0.2cm; text-align:left; vertical-align:top; text-align:left; padding-top:0.1cm; padding-bottom:0.1cm;">ICC</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.00</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2">0.00</td> <td style=" padding:0.2cm; text-align:left; vertical-align:top; padding-top:0.1cm; padding-bottom:0.1cm; text-align:left;" colspan="2"> </td> </table> --- ## Model comparisons ```r anova(m3L0, m3L1,m3L4,m3L5) ``` ``` ## Data: dta ## Models: ## m3L0: mathjr3 ~ 1 + (1 | schoolID/classID) ## m3L1: mathjr3 ~ yearstea + (1 | schoolID) + (1 | classID:schoolID) ## m3L4: mathjr3 ~ urban + (1 | schoolID) + (1 | classID:schoolID) ## m3L5: mathjr3 ~ urban + sector + (1 | schoolID) + (1 | classID:schoolID) ## npar AIC BIC logLik deviance Chisq Df Pr(>Chisq) ## m3L0 4 29479 29506 -14735 29471 ## m3L1 5 29477 29511 -14733 29467 4.2435 1 0.0394 * ## m3L4 6 29434 29475 -14711 29422 44.7945 1 2.188e-11 *** ## m3L5 7 29378 29426 -14682 29364 58.2160 1 2.349e-14 *** ## --- ## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1 ``` --- ## Residuals plot ```r library(lattice) qqmath(m3L5, grid=TRUE) ``` <!-- --> --- ## 9th Math vs Centered 7thMath by sector .pull-left[ ```r ggplot(dta, aes(premath_c, mathjr3, color = sector)) + geom_smooth(method = "lm") + geom_jitter(alpha = 0.2) + labs(x = "Centered 7th score", y = "9th Math score") + theme(legend.position = c(.1, .8)) ``` The effect of premath_c on 9th score for student in public school is similar than the student in private school.] .pull-right[ <!-- --> ] --- ## 9th Math vs Centered 7th Math by urban .pull-left[ ```r ggplot(dta, aes(premath_c, mathjr3, color = urban)) + geom_smooth(method = "lm") + geom_jitter(alpha = 0.2) + labs(x = "Centered 7th score", y = "9th Math score") + theme(legend.position = c(.1, .8)) ``` City is higher than town and village.] .pull-right[ <!-- --> ] --- ## 9th Math vs Centered 7th Math by classtype .pull-left[ ```r ggplot(dta, aes(premath_c, mathjr3, color = classtype)) + geom_smooth(method = "lm") + geom_jitter(alpha = 0.2) + labs(x = "Centered 7th score", y = "9th Math score") + theme(legend.position = c(.1, .8)) ``` ] .pull-right[ <!-- --> ] --- ## limiation and summary - Data scale - Add the Fixed effect, than random effect may be decreasing. - Teaching years have nothing to do with math scores, as opposed to what is mentioned in the literature. - 9th's math score is lower than 7th's score. - school and class random effect are very low. --- ### Reference Baker, D. P., Akiba, M., LeTendre, G. K., & Wiseman, A. W. (2001). Worldwide Shadow Education: Outside-School Learning, Institutional Quality of Schooling, and Cross-National Mathematics Achievement. Educational Evaluation and Policy Analysis, 23(1), 1–17. https://doi.org/10.3102/01623737023001001 Bray, Mark . 1999. The Shadow Education System: Private Tutoring and Its Implications for Planners. Paris: IIEP-UNESCO. Bray, M., Zhan, S., Lykins, C., Wang, D., & Kwo, O. (2014). Differentiated demand for private supplementary tutoring: Patterns and implications in Hong Kong secondary education. Economics of Education Review, 38, 24–37. Chmielewski, A. K., & Reardon, S. F. (2016). Patterns of Cross-National Variation in the Association Between Income and Academic Achievement. AERA Open. https://doi.org/10.1177/2332858416649593 Choi, J. (2012). Unequal access to shadow education and its impacts on academic outcomes: Evidence from Korea. Spring 2012 meeting of ISA RC, 28, 10–13. Domingue, B., & Briggs, D. C. (2009). Using linear regression and propensity score matching to estimate the effect of coaching on the SAT. Multiple Linear Regression Viewpoints, 35(1), 12–29 Douglas, D., & Attewell, P. (2017). School mathematics as gatekeeper. The Sociological Quarterly, 58(4), 648–669. https://doi.org/10.1080/00380253.2017.1354733 Goo, J. E. (2000). The relationships between self-resilience, positive emotion, social support and adolescents′ adjustment in family life school life. Unpublished master′s thesis. Busan National University, Busan, South Korea. --- ### Reference Sawchuk, S. (2015). New Studies Find That, for Teachers, Experience Really Does Matter. Education Week. Retrieved March 24, 2015 Kim, Y. C. (2016). Shadow education and the curriculum and culture of schooling in South Korea. New York: Palgrave Macmillan Kuan, P. Y. (2011). Effects of cram schooling on mathematics performance: Evidence from junior high students in Taiwan. Comparative Education Review, 55(3), 342–368. Lauer, P. A., Akiba, M., Wilkerson, S. B., Apthorp, H. S., Snow, D., & MartinGlenn, M. L. (2006). Out-of-school-times programs: A meta-analysis of effects for at-risk students. Review of Educational Research, 76(2), 275–313. Lee, J. S. (2001). The Relationships between school success and social capital in an elementary school: An ethnographic study (in Korean). Study of Educational Ethnography, 4(3), 253–288. Lee, J. H. & Kim, K. K. (2007). The effect of social capital within family and school on the student′s academic achievement (in Korean). Korean Sociology of Education, 13(2), 175–208. Liu, J. (2012). Does cram schooling matter? Who goes to cram school? Evidence from Taiwan. International Journal of Educational Development, 32(1), 46–52. Liu, J., Peng, P. & Luo, L. The Relation Between Family Socioeconomic Status and Academic Achievement in China: A Meta-analysis. Educ Psychol Rev 32, 49–76 (2020). https://doi.org/10.1007/s10648-019-09494-0 Miller, P. and Votruba‐Drzal, E. (2015), Urbanicity and Achievement. Rural Sociol, 80: 362-386. https://doi.org/10.1111/ruso.12067 --- ### Reference Muller, C., & Ellison, C. G. (2001). Religious involvement, social capital, and adolescents’ academic progress: Evidence from the National Education Longitudinal Study of 1988. Sociological Focus, 34(2), 155–183. Reardon, S. F. (2016). School district socioeconomic status, race, and academic achievement. Stanford Center for Educational Policy Analysis. Retrieved from. Stevenson, David Lee, Baker, David P. 1992. “Shadow Education and Allocation in Formal Schooling: Transition to University in Japan.” American Journal of Sociology 97(6):1639-657. Sawada, T., & Kobayashi, S. (1986). An analysis of the effect of arithmetic and mathematics education at juku. Tokyo: National Institute for Educational Research. Yang, H. The role of social capital at home and in school in academic achievement: The case of South Korea. Asia Pacific Educ. Rev. 18, 373–384 (2017). https://doi.org/10.1007/s12564-017-9492-7 Yin M., (2020) “Opportunity for Whom? Understanding Curriculum-Oriented Out-of-School Time Math Learning”, Journal of Critical Thought and Praxis 10(1). doi: https://doi.org/10.31274/jctp.11579 Zhao, G. (2015). Can money ‘buy’ schooling achievement? Evidence from 19 Chinese cities. China Economic Review, 35, 83–104. 關秉寅(2016)。國中讀前段班有差嗎?能力分班對學習成就影響的反事實分析。教育研究集刊,62(1),1-33。