-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathsensen notes .rtf
99 lines (98 loc) · 1.96 KB
/
sensen notes .rtf
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
{\rtf1\ansi\ansicpg936\cocoartf1344\cocoasubrtf720
{\fonttbl\f0\fswiss\fcharset0 Helvetica;\f1\fnil\fcharset134 STHeitiSC-Light;}
{\colortbl;\red255\green255\blue255;}
\paperw11900\paperh16840\margl1440\margr1440\vieww20380\viewh11060\viewkind0
\pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\pardirnatural
\f0\fs36 \cf0 label define europelabel /*\
*/1 \'93
\f1 \'c5\'b7\'d6\'de
\f0 \'94 0 \'93
\f1 \'c6\'e4\'cb\'fb
\f0 \'94,modify\
lab list europelabel\
label value europe europelabel\
\
note gdp : per capita gdp /*\
*/in US$ in 2002\
\
des \
notes \
\
use \'93org\\hdr2004.dta\'94,clear\
\
compress\
\
rename gdp pergdp\
order pergdp rank contin\
\
move contin rank\
\
sort contin pergdp\
order contin pergdp nation \
gsort -contin -pergdp\
\
li contin nation if (contin==3|contin==4)&pergdp<1000,nol\
\
rename pergdp gdp\
\
sum gdp if contin==3|contin==1\
tab contin,sum (gdp)\
bysort contin:sum(gdp)\
\
\
\
\
gen rank2=_n\
order rank*\
gsort contin -gdp\
\pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\pardirnatural
\cf0 bysort contin:gen rank3=_n\
\
use \'93org\\chnhf2000.dta\'94,clear\
tab edu\
\
*case1\
\pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\pardirnatural
\cf0 gen none=1 if edu==1\
tab none,m\
replace none=0 if none==.\
\
*case2\
gen primary=edu==2\
tab pri\
\
*case3\
recode edu 3=1 else=0,gen(jun)\
tab jun\
\
*case4 \
tab edu,gen(edug)\
rename edug4 sen\
\pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\pardirnatural
\cf0 rename edug5 college\
rename edug6 univ\
\
regress inc age occ none primary jun sen college \
regress inc age none primary jun sen college \
\
gen female=sex==2\
gen male=sex==1\
\
table univ sex,c(mean inc )\
gen umale=univ*male \
reg inc univ male umale\
\
\pard\tx566\tx1133\tx1700\tx2267\tx2834\tx3401\tx3968\tx4535\tx5102\tx5669\tx6236\tx6803\pardirnatural
\cf0 \
\
\
\
\
\
\
\
\
\
\
\
}