-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSummary_stat.do
132 lines (87 loc) · 7.56 KB
/
Summary_stat.do
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
*****************************************
****** SUMMARY STATISTICS *****************
*****************************************
*** PPVT***
cd "D:\YL\data""
use "yc_panel.dta",clear
*** Home Input***
* Primary level
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hchore htask hhsize ttmalesib if round==3, by(typesite) statistics(mean sd) nototal columns(statistics) listwise
eststo typesite
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hchore htask hhsize ttmalesib if round==3, by( majorethnic ) statistics(mean sd) nototal columns(statistics) listwise
eststo majorethnic
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hchore htask hhsize ttmalesib if round==3, by( carehedu ) statistics(mean sd) nototal columns(statistics) listwise
eststo carehedu
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hchore htask hhsize ttmalesib if round==3, by(moreable ) statistics(mean sd) nototal columns(statistics) listwise
eststo moreable
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hchore htask hhsize ttmalesib if round==3, by( stuntearly ) statistics(mean sd) nototal columns(statistics) listwise
eststo stuntearly
esttab typesite majorethnic carehedu moreable stuntearly, main(mean) aux(sd) nostar unstack noobs nonote nomtitle nonumber
esttab typesite majorethnic carehedu moreable stuntearly using "./out/homeinput1.tex", replace cells(mean(fmt(2)) sd(par)) nostar unstack ///
nonumber compress nonote noobs label booktabs f collabels(none)
* Secondary level
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hwork hchore htask hhsize ttmalesib if round==5 , by(typesite) statistics(mean sd) nototal columns(statistics) listwise
eststo typesite
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hwork hchore htask hhsize ttmalesib if round==5, by( majorethnic ) statistics(mean sd) nototal columns(statistics) listwise
eststo majorethnic
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hwork hchore htask hhsize ttmalesib if round==5, by( carehedu ) statistics(mean sd) nototal columns(statistics) listwise
eststo carehedu
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hwork hchore htask hhsize ttmalesib if round==5, by(moreable ) statistics(mean sd) nototal columns(statistics) listwise
eststo moreable
estpost tabstat hq_new sv_new cd_new bsstutl advstutl hschool hrsexc hstudy hsleep hplay hwork hchore htask hhsize ttmalesib if round==5, by( stuntearly ) statistics(mean sd) nototal columns(statistics) listwise
eststo stuntearly
esttab typesite majorethnic carehedu moreable stuntearly, main(mean) aux(sd) nostar unstack noobs nonote nomtitle nonumber
esttab typesite majorethnic carehedu moreable stuntearly using "./out/homeinput2.tex", replace cells(mean(fmt(2)) sd(par)) nostar unstack ///
nonumber compress nonote noobs label booktabs f collabels(none)
*******************
*** Schol Input***
*******************
* Primary level
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool tchuni enrol if round==3 & sample==1, by(typesite) statistics(mean sd) nototal columns(statistics) listwise
eststo typesite
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool tchuni enrol if round==3 & sample==1, by(majorethnic) statistics(mean sd) nototal columns(statistics) listwise
eststo majorethnic
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool tchuni enrol if round==3 & sample==1, by(carehedu) statistics(mean sd) nototal columns(statistics) listwise
eststo carehedu
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool tchuni enrol if round==3 & sample==1, by(moreable) statistics(mean sd) nototal columns(statistics) listwise
eststo moreable
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool tchuni enrol if round==3 & sample==1, by(stuntearly) statistics(mean sd) nototal columns(statistics) listwise
eststo stuntearly
esttab typesite majorethnic carehedu moreable stuntearly using "./out/schoolinput11.tex", replace cells(mean(fmt(2)) sd(par)) nostar unstack nonumber compress nonote noobs label booktabs f collabels(none)
***
estpost tabstat tchuni avg_tchyrtot agegr1 enrol if round==3 , by(typesite) statistics(mean sd) nototal columns(statistics) listwise
eststo typesite
estpost tabstat tchuni avg_tchyrtot agegr1 enrol if round==3, by(majorethnic) statistics(mean sd) nototal columns(statistics) listwise
eststo majorethnic
estpost tabstat tchuni avg_tchyrtot agegr1 enrol if round==3, by(carehedu) statistics(mean sd) nototal columns(statistics) listwise
eststo carehedu
estpost tabstat tchuni avg_tchyrtot agegr1 enrol if round==3, by(moreable) statistics(mean sd) nototal columns(statistics) listwise
eststo moreable
estpost tabstat tchuni avg_tchyrtot agegr1 enrol if round==3, by(stuntearly) statistics(mean sd) nototal columns(statistics) listwise
eststo stuntearly
esttab typesite majorethnic carehedu moreable stuntearly using "./out/enrol1.tex", replace cells(mean(fmt(2)) sd(par)) nostar unstack nonumber compress nonote noobs label booktabs f collabels(none)
* Secondary level
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool engchuni mathtchuni if round==5 & sample==1, by(typesite) statistics(mean sd) nototal columns(statistics) listwise
eststo typesite
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool engchuni mathtchuni if round==5 & sample==1, by(majorethnic) statistics(mean sd) nototal columns(statistics) listwise
eststo majorethnic
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool engchuni mathtchuni if round==5 & sample==1, by(carehedu) statistics(mean sd) nototal columns(statistics) listwise
eststo carehedu
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool engchuni mathtchuni if round==5 & sample==1, by(moreable) statistics(mean sd) nototal columns(statistics) listwise
eststo moreable
estpost tabstat facidx seridx device sagei studenr emstud timesch hschool engchuni mathtchuni if round==5 & sample==1, by(stuntearly) statistics(mean sd) nototal columns(statistics) listwise
eststo stuntearly
esttab typesite majorethnic carehedu moreable stuntearly using "./out/schoolinput21.tex", replace cells(mean(fmt(2)) sd(par)) nostar unstack ///
nonumber compress nonote noobs label booktabs f collabels(none)
************
estpost tabstat enrol avg_engtchyrtot avg_mathtchyrtot if round==5 , by(typesite) statistics(mean sd) nototal columns(statistics) listwise
eststo typesite
estpost tabstat enrol avg_engtchyrtot avg_mathtchyrtot if round==5 , by(majorethnic) statistics(mean sd) nototal columns(statistics) listwise
eststo majorethnic
estpost tabstat enrol avg_engtchyrtot avg_mathtchyrtot if round==5 , by(carehedu) statistics(mean sd) nototal columns(statistics) listwise
eststo carehedu
estpost tabstat enrol avg_engtchyrtot avg_mathtchyrtot if round==5 , by(moreable) statistics(mean sd) nototal columns(statistics) listwise
eststo moreable
estpost tabstat enrol avg_engtchyrtot avg_mathtchyrtot if round==5 , by(stuntearly) statistics(mean sd) nototal columns(statistics) listwise
eststo stuntearly
esttab typesite majorethnic carehedu moreable stuntearly using "./out/enrol2.tex", replace cells(mean(fmt(2)) sd(par)) nostar unstack nonumber compress nonote noobs label booktabs f collabels(none)