Tải bản đầy đủ (.docx) (31 trang)

tiểu luận kinh tế lượng 2 explaining factors that affect the working time (minutes that a person spends at paid labor each week) of people in 1975 and 1981

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (370.46 KB, 31 trang )

INTRODUCTION
Econometrics, one of the most crucial branches of economics, is the application of
statistical techniques in evaluation and testing of economic theories. Economists apply
econometric modeling in a variety of specific fields (such as labor economics, development
economics and finance) to shed light on theoretical questions, namely the relationship
between variables of interest. They also use this tool to inform public policy debates, make
business decisions, and forecast future events.
Majoring in International Economics, all of us are aware of the importance of
econometrics. This awareness has been motivating us to learn and do some further research in
order to have an insight of this field. Under the instruction of Mrs. Phuong Mai in
Econometrics I and PhD. Dinh Thi Thanh Binh in Econometrics II, we have built an
econometric model explaining factors that affect the working time (minutes that a person
spends at paid labor each week) of people in 1975 and 1981. Our research is based on the
data set 5_SLP75_81.DTA and accomplished by the usage of a well – known computer
software – Stata.
By accomplishing this assignment, we are greatly grateful to our lecturer, Mrs. Binh. She
has provided us with a large amount of precious knowledge through her lessons, which plays
a role in the completion of our report. Furthermore, in our process of searching for ideas, she
has offered suggestions, given us specific examples and advice. Under her detailed
instruction, our work has become more oriented and completed. Moreover, we expected that
we would gain more understanding of econometrics and the appliances of it; all of us will be
fluent to use Stata software.
As this is our first research about econometrics, it may contain some mistakes or
misunderstanding. Therefore, we are looking forward to hearing your comments, suggestions
or even criticism to better our assignment.
I. LITERATURE REVIEW
1. Reason for choosing the topic.
Working time varies substantially among countries and among generation, but also within
countries, e.g. due to the prevalence of part-time work and working hours regulations or
agreements. Due to the direct relation between the number of working hours and the labor
productivity, understanding how they interact with each other is an important element of


1


understanding labor demand, and has important implications for the regulation of working
hours and company’s management. Low productivity is not an individual phenomenon but a
universal problem. Therefore, improving the labor productivity resulted from change in
working time is not only related to the development of the national economy, but also directly
affects the sustainable and stable development of the enterprise. The increase of labor
productivity is the basis of the accumulation of wealth, the increase of real wages and the
improvement of living standards, while the increase of labor productivity is helpful to restrain
the inflation caused by the rise in nominal wages. Therefore, it is urgent to study the problem
of working hours, especially laborers in 1975 and 1981, who are considered as the
experienced generation contributing significantly to the whole economic status.
The issue of working time is meaningful in each country around the word, but it is hard for
each country to really make clear of important factors to promote it and what are not. There
are so many factors are affecting the working time as well as labor productivity. Recognizing
the urgency of analyzing and evaluating the effectiveness of the activity in business, within
the scope of this paper, we would like to analyze the striking impact of age, educational,
health level, gender, marital status and the amount of weekly relaxing time to minutes spent
on working of laborers in 1975 and 1981.
2. Methods of analysis
To get a thorough understanding about this issue, we should set up a Fixed-effect model
and with the support of Stata software to measure the extend of each factor’s influence on the
working time of workers in 1975 and 1981.
Stata
Stata is a general-purpose statistical software package created in 1985 by StataCorp. Most
of its users work in research, especially in the fields of economics, sociology, political
science, biomedicine and epidemiology.
Stata's capabilities include data management, statistical analysis, graphics, simulations,
regression, and custom programming. It also has a system to disseminate user-written

programs that lets it grow continuously.
Fixed-effect model
A statistical model of the output of a business or manufacturing process that treats all
variables as non-random values. Fixed effects models are used to determine optimal values
for inputs to business or manufacturing processes when random factors are judged not to be
present in the process, or determined not to have an effect on the process output.
2


DESCRIPTION OF THE DATA
I. Overview:

The data that we use for the research is a secondary data that was collected
into the file 5_SLP75_81.DTA by Ph.D Dinh Thi Thanh Binh.
The data include the same groups of observation (age, education, marriage,
health condition, young kids, gender,...) observed in two differnt time (1975 and
1981).
=> This is a Panel Data sample.
II. Description of the data:

- To describe the data of the file, we use the command des and have the result:

. des
Contains data from C:\Users\Hieu\Desktop\KTL 2\KTL2_CLC2\KTL2_CLC\file data_ful
> l\5_SLP75_81.DTA
obs:
239
vars:
20
17 Aug 1999 22:56

size:
6,214

variable name
age75
educ75
educ81
gdhlth75
gdhlth81
male
marr75
marr81
slpnap75
slpnap81
totwrk75
totwrk81
yngkid75
yngkid81
ceduc
cgdhlth
cmarr
cslpnap
ctotwrk
cyngkid

storage
type
byte
byte
byte

byte
byte
byte
byte
byte
int
int
int
int
byte
byte
byte
byte
byte
int
int
byte

display
format

value
label

%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g

%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g
%9.0g

variable label
age in 1975
years educ in '75
years educ in '81
= 1 if good hlth in '75
=1 if good hlth in '81
=1 if male
= 1 if married in '75
=1 if married in '81
mins slp wk, inc naps, '75
mins slp wk, inc naps, '81
minutes worked per week, '75
minutes worked per week, '81
= 1 if child < 3, '75
=1 if child < 3, '81

change in educ
change in gdhlth
change in marr
change in slpnap
change in totwrk
change in yngkid

Sorted by:
.

3


We can see that the data shows the information of factors that affect to the
total working time per week (minutes per week), based on 239 observations in
2 different years 1975 and 1981.
- In order to run the panel model, we have to reshape the original data into the
new data that is suitable for installing panel data:
ID
1
1
2
2
3
3
4
4
5
5
6

6
7
7
8
8
9
9
10
10
11
11
12
12
13
13
14
14
15
15
16
16
17
17
18
18
19
19
20
20
21


Year
age
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

educ
46
52
39
45
55
61
39
45
54
60
32
38
30
36

27
33
33
39
51
57
23
29
46
52
38
44
30
36
39
45
53
59
59
65
54
60
35
41
46
52
36

gdhlth
16

16
16
16
15
15
16
16
17
17
16
16
16
16
16
16
17
19
14
14
16
16
17
19
12
12
10
10
12
12
12

12
14
14
14
14
12
12
17
18
12

male
1
1
1
1
1
0
1
1
1
1
1
1
1
1
0
1
1
1

1
1
1
1
1
1
1
1
1
0
1
0
1
0
1
0
1
1
1
1
1
1
1

4

marr
1
1
1

1
1
1
1
1
0
0
1
0
1
1
1
1
1
0
0
1
1
1
0
0
1
0
0
1
0
0
1
1
0

0
0
0
0
0
1
1
0

0
1
1
0
1
1
1
1
1
1
1
1
1
1
0
0
1
1
1
1
1

1
1
1
1
1
0
0
1
1
1
1
1
1
1
1
1
1
1
1
1

totwrk
2050
2430
2713
2610
2493
0
2778
1787

3118
552
2348
2567
1571
2272
3421
400
1853
2617
0
1312
2700
3292
2526
2075
2948
3207
2570
2705
2620
2932
3588
4122
958
630
2575
2600
3135
2958

3003
1887
3188


21
22
22
23
23
24
24
25
25
26
26
27
27
28
28
29
29
30
30
31
31
32
32
33
33

34
34
35
35
36
36
37
37
38
38
39
39
40
40
41
41
42
42
43
43
44
44
45
45
46

1981
1975
1981
1975

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

42
25
31
29
35
37
43
31
37
43
49
35
41

37
43
28
34
35
41
56
62
47
53
25
31
35
41
28
34
24
30
34
40
36
42
40
46
64
70
48
54
32
38

36
42
23
29
59
65
28

12
17
18
12
12
12
12
17
17
12
12
12
14
12
14
16
16
12
12
11
12
16

16
16
16
12
12
12
12
13
13
16
18
12
12
13
13
12
12
12
12
12
12
16
18
13
14
12
13
16

1

1
1
1
1
1
0
1
1
1
0
1
1
1
1
1
1
1
0
1
0
1
1
1
0
1
1
1
1
1
1

1
1
1
1
1
1
0
1
1
0
1
0
1
1
1
1
1
0
1

5

1
0
1
0
0
1
0
0

0
0
0
1
0
1
0
1
1
1
0
0
1
1
0
1
1
0
1
1
1
0
1
1
1
1
1
0
1
0

1
1
0
0
0
0
0
1
0
1
1
1

1
0
1
0
0
1
1
1
1
1
1
1
1
1
1
0
0

0
0
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
0
1
1
1
1
1

1
1
1

587
2363
2610
2270
1065
1851
1400
2592
1049
1995
650
2480
2037
2049
2562
1175
2437
1350
2750
3242
1935
2638
3245
875
237
1125

2330
1497
2362
2686
3510
2205
2475
3598
1994
3276
3350
2508
1287
900
900
2108
1775
1905
362
2477
3727
1013
867
2568


46
47
47
48

48
49
49
50
50
51
51
52
52
53
53
54
54
55
55
56
56
57
57
58
58
59
59
60
60
61
61
62
62
63

63
64
64
65
65
66
66
67
67
68
68
69
69
70
70
71

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981

1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981

1975
1981
1975
1981
1975
1981
1975

34
41
47
27
33
33
39
23
29
56
62
51
57
60
66
52
58
47
53
29
35
44

50
55
61
37
43
46
52
30
36
64
70
25
31
31
37
37
43
39
45
25
31
55
61
60
66
36
42
35

16

17
18
17
17
12
12
12
12
13
13
12
12
17
17
8
8
12
12
12
12
9
9
17
18
17
17
11
11
16
16

12
12
17
19
12
12
12
12
11
11
12
12
12
12
12
14
10
11
12

1
1
1
1
0
1
1
1
1
1

0
0
0
1
0
0
0
1
0
1
1
1
0
1
1
1
1
1
0
1
1
1
1
1
0
1
1
1
1
1

1
1
1
1
1
1
1
1
1
1

6

1
0
1
1
1
1
0
1
1
0
1
0
1
1
0
1
1

0
1
1
0
1
1
0
0
0
1
1
0
1
0
1
0
1
1
1
1
1
1
1
1
1
1
1
1
1
1

1
1
1

1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
0
0
1
1
1
1
1

1
1
1
1
1
1
1
1
1
1
1
1
0
1
1
1
1
1
1
1
1
1
1
0

1500
3518
3817
305
905

1553
2390
0
0
375
0
3105
3267
1988
2467
1733
1805
2351
2475
2263
1537
2616
2692
2501
2425
2125
825
1738
530
0
787
0
0
2150
2200

2325
2570
3148
2515
1775
1062
1350
1350
188
2712
4325
0
2430
2592
2250


71
72
72
73
73
74
74
75
75
76
76
77
77

78
78
79
79
80
80
81
81
82
82
83
83
84
84
85
85
86
86
87
87
88
88
89
89
90
90
91
91
92
92

93
93
94
94
95
95
96

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

41

53
59
33
39
32
38
35
41
29
35
40
46
48
54
30
36
28
34
36
42
52
58
36
42
33
39
40
46
32
38

51
57
26
32
40
46
33
39
30
36
60
66
53
59
40
46
47
53
54

12
12
13
16
16
16
16
17
17
16

16
12
12
12
12
12
12
17
18
9
9
17
18
16
17
12
12
17
18
12
12
16
16
12
12
14
14
12
17
12

12
8
8
12
12
16
16
12
12
14

1
1
1
1
0
1
1
1
1
1
1
1
1
1
1
1
1
1
0

1
1
1
1
1
1
1
1
1
0
1
1
1
1
0
0
1
1
1
0
1
1
1
1
0
0
1
1
1
0

0

7

1
1
1
1
1
0
1
0
0
1
1
0
1
0
0
1
0
1
0
1
1
0
0
0
1
1

1
0
0
1
0
0
1
1
1
1
0
1
1
0
1
0
0
1
0
0
1
1
1
1

0
1
1
1
1

0
0
1
1
1
1
1
1
1
1
1
1
0
0
1
1
1
1
1
1
1
1
1
1
1
0
0
0
1
1

1
1
1
1
1
0
1
1
0
0
1
1
1
1
1

1162
2506
2591
2563
1762
2763
3047
2048
692
2418
2537
2420
2512
2735

1675
2163
2175
3556
3067
1555
3765
3869
2607
2281
1882
2488
2250
1263
2150
113
0
2325
1800
388
0
3230
4195
2755
2287
2475
2662
2975
0
0

0
2388
2425
1538
2140
2150


96
97
97
98
98
99
99
100
100
101
101
102
102
103
103
104
104
105
105
106
106
107

107
108
108
109
109
110
110
111
111
112
112
113
113
114
114
115
115
116
116
117
117
118
118
119
119
120
120
121

1981

1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981

1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

60
33
39
32
38
33
39
35
41
57

63
40
46
28
34
23
29
24
30
26
32
36
42
32
38
35
41
29
35
33
39
48
54
26
32
42
48
55
61
26

32
63
69
26
32
50
56
28
34
37

14
14
14
12
12
12
12
12
12
12
12
12
12
12
12
14
15
15
16

12
12
9
10
12
12
16
16
16
16
8
8
11
11
12
12
11
11
14
14
15
15
5
5
17
17
12
12
14
15

14

1
1
1
1
1
1
0
1
1
1
1
1
1
1
0
1
1
1
1
1
1
1
1
1
1
1
1
1

1
0
0
1
1
1
1
1
1
1
0
1
1
0
1
1
1
1
1
1
1
1

8

1
0
1
0
0

0
1
0
1
1
0
0
1
1
1
1
1
1
1
0
0
1
0
1
0
0
1
0
0
0
1
0
1
0
0

1
1
1
1
0
1
1
1
1
1
0
1
1
1
1

1
1
1
1
1
1
1
1
1
1
1
1
1
1

1
0
0
1
1
1
0
1
1
1
1
1
0
1
1
1
1
0
0
1
1
1
1
1
1
1
1
0
1
1

1
1
1
0
0
1

2512
2488
2525
1050
2437
1806
1352
2113
1973
588
0
2325
2300
0
2092
2195
1962
1920
2300
2250
930
2896
2630

2276
950
68
2865
1125
2175
2488
2485
2138
375
1880
2250
2946
1662
375
1360
4065
570
363
525
2775
2400
3194
2815
1168
2954
0


121

122
122
123
123
124
124
125
125
126
126
127
127
128
128
129
129
130
130
131
131
132
132
133
133
134
134
135
135
136
136

137
137
138
138
139
139
140
140
141
141
142
142
143
143
144
144
145
145
146

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

43
53
59
44
50
54
60
36
42
30
36
28
34
25
31
38
44
29
35

27
33
35
41
25
31
29
35
32
38
58
64
26
32
56
62
45
51
25
31
34
40
44
50
27
33
26
32
47
53

43

15
15
15
16
16
9
9
17
19
12
12
12
12
12
12
9
9
12
12
15
15
12
12
17
17
12
12
12

12
8
8
12
12
5
5
12
12
16
16
11
11
16
16
16
16
13
13
8
8
12

1
1
1
1
1
1
1

1
1
1
1
1
1
1
1
0
1
1
1
1
0
1
1
1
0
1
1
1
1
1
1
0
1
1
0
1
1

1
1
1
0
1
1
1
0
0
1
1
1
1

9

1
1
1
1
1
1
0
0
1
0
1
1
1
1

1
0
0
1
1
1
0
0
1
0
0
1
0
0
1
1
0
0
0
0
0
0
1
1
0
1
0
1
0
0

1
0
0
0
0
0

1
0
1
1
1
1
1
1
1
1
1
0
0
1
1
1
1
1
1
1
1
1
1

1
1
1
0
1
1
1
1
0
0
0
0
1
1
1
0
1
1
1
1
1
1
1
1
1
1
0

1437
1188

2325
2513
875
1208
1637
1913
2485
3146
2347
2791
2312
2250
2920
2681
2635
1800
2312
2238
1280
1588
2637
2820
2030
2313
2970
2965
1629
2263
1212
2506

2960
2880
0
2326
2437
3075
1000
2463
0
1075
1105
3180
1745
2711
2337
2388
1162
2325


146
147
147
148
148
149
149
150
150
151

151
152
152
153
153
154
154
155
155
156
156
157
157
158
158
159
159
160
160
161
161
162
162
163
163
164
164
165
165
166

166
167
167
168
168
169
169
170
170
171

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981

1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981

1975

49
60
66
30
36
60
66
33
39
48
54
52
58
37
43
32
38
55
61
33
39
33
39
25
31
37
43
50

56
52
58
32
38
27
33
36
42
52
58
36
42
65
71
34
40
26
32
34
40
27

12
12
12
13
13
11
12

17
19
17
19
17
18
12
12
17
18
12
12
12
13
17
17
12
12
12
12
12
12
17
17
6
7
12
16
10
10

10
10
12
12
7
7
15
15
12
12
12
12
14

1
1
1
0
0
1
0
1
0
0
0
1
0
0
1
1

1
1
0
1
1
1
1
1
1
1
1
1
1
1
1
1
1
0
0
1
0
0
1
1
1
0
1
1
1
0

1
1
1
1

10

1
0
1
0
1
1
1
0
0
1
1
0
1
1
0
1
1
1
0
1
1
1
1

1
0
1
0
1
1
0
0
0
0
0
1
0
1
1
1
1
0
1
1
1
1
0
1
1
0
1

1
0

0
1
1
0
1
1
0
0
1
1
1
1
0
1
0
1
0
1
0
0
1
0
0
1
1
0
0
0
1
1

1
1
0
0
1
0
0
1
1
0
0
0
0
1
1
0
0
1

2322
2013
687
2533
2845
0
0
353
1575
838
0

2588
1750
2188
2392
2353
3245
2288
2262
1125
2212
2366
1390
1510
1535
3213
2175
3411
3035
1138
2100
3533
2825
2050
825
2587
0
2140
455
3225
2167

2143
2437
2808
2627
950
1587
2505
2082
2466


171
172
172
173
173
174
174
175
175
176
176
177
177
178
178
179
179
180
180

181
181
182
182
183
183
184
184
185
185
186
186
187
187
188
188
189
189
190
190
191
191
192
192
193
193
194
194
195
195

196

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

33
40
46
34
40
31
37

39
45
26
32
25
31
30
36
38
44
31
37
57
63
27
33
27
33
41
47
44
50
61
67
62
68
35
41
37
43

45
51
34
40
49
55
44
50
42
48
52
58
51

14
14
14
12
13
16
16
12
12
17
18
12
12
12
12
14

15
12
12
9
9
15
15
12
12
16
16
12
12
12
12
8
8
12
13
12
12
17
17
17
19
17
19
8
8
12

122
12
12
8

1
1
1
1
1
1
1
1
0
1
1
1
1
1
0
1
1
1
1
1
0
1
1
1
0

1
1
1
1
1
0
1
0
1
0
1
0
1
1
1
1
1
1
0
0
1
1
1
1
0

11

0
1

1
0
1
1
0
1
1
0
1
1
0
0
0
1
1
0
1
0
1
0
1
1
1
1
1
1
1
1
1
1

1
1
1
1
1
1
1
1
1
1
1
1
0
1
0
0
1
1

1
0
1
0
0
1
1
1
1
1
1

1
1
0
0
1
0
1
1
0
0
1
1
1
0
0
0
0
0
1
0
1
1
1
1
1
0
1
0
1
1

0
1
1
1
1
1
0
0
1

2630
1755
2300
2588
3222
4058
3890
3595
3197
2941
2475
2931
2292
2425
2375
1578
737
2276
1130
2775

2412
2125
640
1863
1050
2218
2390
1208
2550
375
765
2475
0
3171
3997
4805
3774
1543
2400
2443
2707
2450
2050
1175
1175
3275
862
2100
1050
2525



196
197
197
198
198
199
199
200
200
201
201
202
202
203
203
204
204
205
205
206
206
207
207
208
208
209
209
210

210
211
211
212
212
213
213
214
214
215
215
216
216
217
217
218
218
219
219
220
220
221

1981
1975
1981
1975
1981
1975
1981

1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981

1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975

57
62
68
58
64
60
66
39
45
43
49
44
50
35
41
42

48
61
67
30
36
33
39
44
50
32
38
50
56
32
38
56
62
28
34
32
38
24
30
44
50
61
67
28
34
27

33
39
45
31

8
1
6
7
7
12
12
12
12
9
9
8
8
16
16
16
16
17
19
16
18
17
19
17
19

16
16
17
17
12
12
17
18
14
15
11
11
12
12
12
12
12
12
17
19
16
16
17
19
12

0
0
0
0

0
1
1
1
0
1
1
1
1
1
1
1
0
1
0
1
1
1
1
1
0
1
1
1
1
1
1
0
0
1

1
0
1
0
0
0
1
1
1
1
1
1
0
1
1
1

12

0
1
0
0
1
0
1
0
1
1
0

0
0
1
1
1
0
0
1
0
0
1
1
1
1
0
1
1
0
1
0
0
1
0
0
1
1
1
1
1
0

1
0
0
0
1
0
1
1
0

1
1
1
0
0
1
1
1
1
1
1
1
1
0
1
1
1
1
1
1

1
1
0
1
1
1
1
0
0
0
1
0
0
0
0
0
0
1
1
0
0
0
0
0
0
0
1
0
1
0


0
0
0
0
0
2560
0
2393
1412
2666
3940
2701
1275
1470
2175
2535
3997
2725
0
2905
2577
3080
2722
2815
3250
2433
2650
2163
2532

940
3297
2601
2300
2206
1457
650
2020
1675
2387
2880
2237
1563
837
2606
1505
2538
2637
2026
1100
2698


221
222
222
223
223
224
224

225
225
226
226
227
227
228
228
229
229
230
230
231
231
232
232
233
233
234
234
235
235
236
236
237
237
238
238
239
239


1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981
1975
1981

1975
1981
1975
1981
1975
1981
1975
1981

37
33
39
44
50
25
31
31
37
32
38
33
39
34
40
54
60
23
29
42
48

54
60
37
43
43
49
44
50
29
35
37
43
24
30
40
46

13
12
12
12
12
12
12
14
14
12
12
12
12

16
16
16
16
9
12
14
16
17
18
14
14
12
12
8
9
12
12
6
6
16
16
14
14

0
1
1
1
1

1
1
1
1
1
0
1
0
1
1
1
1
1
0
1
1
1
0
1
1
1
1
1
1
1
1
0
0
1
1

1
0

0
1
1
1
1
1
1
1
0
0
1
0
1
0
0
1
0
0
0
1
0
1
0
0
1
1
1

1
0
1
1
1
1
1
0
1
1

1
1
1
0
1
1
1
1
0
0
1
1
1
1
1
1
1
1
0

1
0
1
1
1
1
0
0
1
1
1
1
0
0
1
1
1
1

2150
2740
2175
2250
2555
2400
1850
3615
2425
2100
1957

2788
2462
2758
1485
2571
1187
3825
1112
2575
2257
1971
2247
4011
1825
1673
1610
3071
2312
2100
2390
1751
957
2438
2137
2485
2392

- Then, we create a new dummy variable y81 by using the following commands:
. gen y81=1 if year==1981
(239 missing values generated)

.
. replace y81=0 if year==1975
(239 real changes made)

After reshaping the data, we use the command des to describe the new data:

13


. des
Contains data
obs:
vars:
size:

478
9
7,648

variable name

storage
type

display
format

ID
year
age

educ

int
int
byte
int

%10.0g
%10.0g
%10.0g
%10.0g

gdhlth

byte

%10.0g

male
marr
totwrk
y81

byte
byte
int
float

%10.0g
%10.0g

%10.0g
%9.0g

value
label

variable label
ID
year (1975 or 1981)
age in that year
years of education counted in
that year
= 1 if in good heallth in that
year
male
marr
totwrk

We use the command sum to check the number of observations (Obs), the
mean values (Mean), Standard Deviation (Std. Dev.), the maximum value (Max)
and the minimum values (Min) of the variables.
. sum
Variable

Obs

Mean

ID
year

age
educ
gdhlth

478
478
478
478
478

120
1978
42.01255
13.5251
.790795

male
marr
totwrk
y81

478
478
478
478

.6025105
.7426778
2043.659
.5


Std. Dev.

Min

Max

69.06503
3.003143
11.45586
5.784965
.4071672

1
1975
23
1
0

239
1981
71
122
1

.4898915
.4376164
972.0307
.5005238


0
0
0
0

1
1
4805
1

III. Choosing the dependent and independent variables:

In order to find out the effect of some significant factors on the total working
time per week of a person, we decided to run the model with:



Dependent variable: totwrk
Independent variable:
X1: age
X2: educ
X3: gdhlth
X4: marr
14


X5: y81
male is a dummy variable which unchanged overtime, so we can drop it drom
the model.


PANEL DATA ANALYSIS
Before using the command xtreg, we need to set Stata to handle panel data
by using command xtest:
. xtset ID year
panel variable:
time variable:
delta:

I

ID (strongly balanced)
year, 1975 to 1981, but with gaps
1 unit

Choosing the most suitable model

1. Breusch - Pagan test
To choose between FE/RE or POLS, we use Breusch- Pagan test for the
significant difference across units by using the commands xtreg and xttest0:

15


. xtreg totwrk age educ gdhlth marr y81, re
Random-effects GLS regression
Group variable: ID

Number of obs
Number of groups


=
=

478
239

R-sq:

Obs per group: min =
avg =
max =

2
2.0
2

within = 0.0714
between = 0.0900
overall = 0.0835

corr(u_i, X)

Wald chi2(5)
Prob > chi2

= 0 (assumed)

totwrk

Coef.


Std. Err.

z

P>|z|

age
educ
gdhlth
marr
y81
_cons

-17.22136
-7.606707
270.9966
113.0862
-120.1202
2631.825

4.511235
7.367247
106.4126
101.8562
77.55897
250.8902

sigma_u
sigma_e

rho

532.209
765.40934
.32590854

(fraction of variance due to u_i)

-3.82
-1.03
2.55
1.11
-1.55
10.49

0.000
0.302
0.011
0.267
0.121
0.000

=
=

41.27
0.0000

[95% Conf. Interval]
-26.06322

-22.04625
62.43178
-86.54837
-272.133
2140.089

-8.379504
6.832832
479.5614
312.7207
31.8926
3123.56

. xttest0
Breusch and Pagan Lagrangian multiplier test for random effects
totwrk[ID,t] = Xb + u[ID] + e[ID,t]
Estimated results:
Var
totwrk
e
u
Test:

sd = sqrt(Var)

944843.6
585851.5
283246.4

972.0307

765.4093
532.209

Var(u) = 0
chibar2(01) =
Prob > chibar2 =

23.96
0.0000

.

We can see that Prob > chibar2 = 0.0000 < 0.05→ Reject
→ Using Random effects/ Fixed effects Model rather than the Pooled OLS.

16


2. Hausman test
To decide between fixed or random effects we run Hausman test where null
hypothesis is that the preferred model is random effects vs. the alternative the
fixed effects.

We use the following commands:
xtreg slpnap d81 age educ gdhlth marr totwrk yngkid,fe
est store fe
xtreg slpnap d81 age educ gdhlth marr totwrk yngkid,re
hausman fe
. xtreg totwrk y81 age educ gdhlth marr ,fe
note: y81 omitted because of collinearity

Fixed-effects (within) regression
Group variable: ID

Number of obs
Number of groups

=
=

478
239

R-sq:

Obs per group: min =
avg =
max =

2
2.0
2

within = 0.0829
between = 0.0643
overall = 0.0630

corr(u_i, Xb)

F(4,235)
Prob > F


= -0.2925

totwrk

Coef.

y81
age
educ
gdhlth
marr
_cons

0
-40.43996
-20.24237
111.3827
87.00893
3863.725

sigma_u
sigma_e
rho

808.64708
765.40934
.52744828

F test that all u_i=0:


Std. Err.

t

(omitted)
12.49673
9.832893
137.6032
165.1573
590.2765

-3.24
-2.06
0.81
0.53
6.55

P>|t|

0.001
0.041
0.419
0.599
0.000

=
=

5.31

0.0004

[95% Conf. Interval]

-65.05989
-39.61426
-159.7108
-238.3691
2700.815

-15.82003
-.8704933
382.4762
412.387
5026.634

(fraction of variance due to u_i)
F(238, 235) =

.
. est store fe

17

2.12

Prob > F = 0.0000


. xtreg totwrk y81 age educ gdhlth marr,re

Random-effects GLS regression
Group variable: ID

Number of obs
Number of groups

=
=

478
239

R-sq:

Obs per group: min =
avg =
max =

2
2.0
2

within = 0.0714
between = 0.0900
overall = 0.0835

corr(u_i, X)

Wald chi2(5)
Prob > chi2


= 0 (assumed)

totwrk

Coef.

Std. Err.

z

P>|z|

y81
age
educ
gdhlth
marr
_cons

-120.1202
-17.22136
-7.606707
270.9966
113.0862
2631.825

77.55897
4.511235
7.367247

106.4126
101.8562
250.8902

sigma_u
sigma_e
rho

532.209
765.40934
.32590854

(fraction of variance due to u_i)

-1.55
-3.82
-1.03
2.55
1.11
10.49

0.121
0.000
0.302
0.011
0.267
0.000

=
=


41.27
0.0000

[95% Conf. Interval]
-272.133
-26.06322
-22.04625
62.43178
-86.54837
2140.089

31.8926
-8.379504
6.832832
479.5614
312.7207
3123.56

. hausman fe
Coefficients
(b)
(B)
fe
.
age
educ
gdhlth
marr


-40.43996
-20.24237
111.3827
87.00893

(b-B)
Difference

-17.22136
-7.606707
270.9966
113.0862

-23.2186
-12.63567
-159.6139
-26.07723

sqrt(diag(V_b-V_B))
S.E.
11.65406
6.512254
87.24111
130.0086

b = consistent under Ho and Ha; obtained from xtreg
B = inconsistent under Ha, efficient under Ho; obtained from xtreg
Test:

Ho:


difference in coefficients not systematic
chi2(4) = (b-B)'[(V_b-V_B)^(-1)](b-B)
=
10.02
Prob>chi2 =
0.0401

We can see that Prob>chi2 = 0.0401 < 0.05→ Reject
→ Choose fixed effects model (FE)

18


IV. FIXED EFFECT MODEL

1. Fixed effects: comparing xtreg (with fe), regress (OLS with dummies)
and areg
An unobserved effects model for total minutes of sleeping per week is
We use the following commands:
. xtset ID year
panel variable:
time variable:
delta:

ID (strongly balanced)
year, 1975 to 1981, but with gaps
1 unit

. xtreg totwrk educ gdhlth marr,fe

Fixed-effects (within) regression
Group variable: ID

Number of obs
Number of groups

=
=

478
239

R-sq:

Obs per group: min =
avg =
max =

2
2.0
2

within = 0.0421
between = 0.0063
overall = 0.0163

corr(u_i, Xb)

F(3,236)
Prob > F


= -0.0587

totwrk

Coef.

educ
gdhlth
marr
_cons

-23.85516
262.6089
103.3492
2081.878

9.963428
131.9965
168.3603
216.9192

sigma_u
sigma_e
rho

794.63064
780.61827
.50889463


(fraction of variance due to u_i)

F test that all u_i=0:

Std. Err.

t
-2.39
1.99
0.61
9.60

F(238, 236) =

19

P>|t|

=
=

0.017
0.048
0.540
0.000

1.99

3.45
0.0172


[95% Conf. Interval]
-43.48378
2.566857
-228.3318
1654.532

-4.226539
522.6509
435.0302
2509.223

Prob > F = 0.0000


. estimates store fixed
. xi: reg totwrk educ gdhlth marr i.ID
i.ID
_IID_1-239
(naturally coded; _IID_1 omitted)
Source

SS

df

MS

Model
Residual


306880281
143810114

241
236

1273362.16
609364.89

Total

450690395

477

944843.596

Std. Err.

t

Number of obs
F(241,
236)
Prob > F
R-squared
Adj R-squared
Root MSE


478
2.09
0.0000
0.6809
0.3551
780.62

totwrk

Coef.

educ
gdhlth
marr
_IID_2
_IID_3
_IID_4
_IID_5
_IID_6
_IID_7
_IID_8
_IID_9
_IID_10
_IID_11
_IID_12
_IID_13
_IID_14
_IID_15
_IID_16
_IID_17

_IID_18
_IID_19
_IID_20
_IID_21
_IID_22
_IID_23
more

-23.85516
262.6089
103.3492
421.5
-937.7253
-9.17458
-432.8194
165.8254
-370.1746
-146.521
-8.964263
-1683.385
704.3254
56.53574
690.4048
437.3481
520.2092
1599.209
-1414.08
248.1151
659.4048
189.1082

-499.5952
282.2827
-616.2461

9.963428
131.9965
168.3603
780.6183
787.9864
785.1441
785.2176
785.1441
785.1441
787.9149
785.4175
785.3763
785.1441
785.4175
786.1138
790.3754
788.9674
788.9674
788.1876
785.3763
786.1138
785.3017
786.1138
780.7613
786.196


-2.39
1.99
0.61
0.54
-1.19
-0.01
-0.55
0.21
-0.47
-0.19
-0.01
-2.14
0.90
0.07
0.88
0.55
0.66
2.03
-1.79
0.32
0.84
0.24
-0.64
0.36
-0.78

0.017
0.048
0.540
0.590

0.235
0.991
0.582
0.833
0.638
0.853
0.991
0.033
0.371
0.943
0.381
0.581
0.510
0.044
0.074
0.752
0.402
0.810
0.526
0.718
0.434

-43.48378
2.566857
-228.3318
-1116.37
-2490.111
-1555.961
-1979.751
-1380.961

-1916.961
-1698.766
-1556.289
-3230.629
-842.4609
-1490.789
-858.2919
-1119.744
-1034.109
44.89069
-2966.863
-1299.129
-889.2919
-1357.989
-2048.292
-1255.869
-2165.105

-4.226539
522.6509
435.0302
1959.37
614.6607
1537.612
1114.112
1712.612
1176.612
1405.724
1538.361
-136.1411

2251.112
1603.861
2239.101
1994.44
2074.528
3153.528
138.7019
1795.359
2208.101
1736.205
1049.101
1820.435
932.6126

_IID_231
_IID_232
_IID_233
_IID_234
_IID_235
_IID_236
_IID_237
_IID_238
_IID_239
_cons

152.1448
-15.58741
578.6151
-642.2461
220.9117

-142.0952
-810.2681
-4.17458
230.4195
2307.399

780.6819
788.0346
785.3763
786.196
788.6152
786.1138
802.9182
785.1441
788.1876
596.6605

0.19
-0.02
0.74
-0.82
0.28
-0.18
-1.01
-0.01
0.29
3.87

0.846
0.984

0.462
0.415
0.780
0.857
0.314
0.996
0.770
0.000

-1385.851
-1568.068
-968.6287
-2191.105
-1332.713
-1690.792
-2392.071
-1550.961
-1322.363
1131.938

1690.14
1536.893
2125.859
906.6126
1774.536
1406.601
771.5345
1542.612
1783.202
3482.86


20

P>|t|

=
=
=
=
=
=

[95% Conf. Interval]


. estimates store ols
. areg totwrk educ gdhlth marr, absorb (ID)
Linear regression, absorbing indicators

totwrk

Coef.

educ
gdhlth
marr
_cons

-23.85516
262.6089

103.3492
2081.878

ID

Number of obs
F(
3,
236)
Prob > F
R-squared
Adj R-squared
Root MSE

Std. Err.

t

9.963428
131.9965
168.3603
216.9192

F(238, 236) =

P>|t|

-2.39
1.99
0.61

9.60

0.017
0.048
0.540
0.000

1.994

0.000

-43.48378
2.566857
-228.3318
1654.532

. estimates table fixed ols areg, star stats (N r2 r2_a)

educ
gdhlth
marr
_IID_2
_IID_3
_IID_4
_IID_5
_IID_6
_IID_7
_IID_8
_IID_9
_IID_10

_IID_11
_IID_12
_IID_13
_IID_14
_IID_15
_IID_16
_IID_17
_IID_18
_IID_19
_IID_20
_IID_21
more

fixed
-23.855159*
262.60887*
103.34916

ols
-23.855159*
262.60887*
103.34916
421.5
-937.7253
-9.1745801
-432.81942
165.82542
-370.17458
-146.52098
-8.9642629

-1683.3849*
704.32542
56.535737
690.40479
437.34806
520.20922
1599.2092*
-1414.0805
248.1151
659.40479
189.10816
-499.59521

21

478
3.45
0.0172
0.6809
0.3551
780.6183

[95% Conf. Interval]

. estimates store areg

Variable

=
=

=
=
=
=

areg
-23.855159*
262.60887*
103.34916

-4.226539
522.6509
435.0302
2509.223

(239 categories)


_IID_233
_IID_234
_IID_235
_IID_236
_IID_237
_IID_238
_IID_239
_cons
N
r2
r2_a


2081.8776***
478
.04205411
-.93618724

578.6151
-642.24605
220.91173
-142.09521
-810.26813
-4.1745801
230.41954
2307.3991***
478
.68091152
.35506269

2081.8776***
478
.68091152
.35506269

legend: * p<0.05; ** p<0.01; *** p<0.001

All three commands have the same results.

According to the fixed effects regression:

- corr(u_i, Xb) = -0.0587 0 The errors u are correlated with the regressors
in the fixed effects model.

- rho = 0.50889463 50.89% of the variance is due to difference across
panels.
- The coefficient = -23.8551 shows that: with other factors fixed, one more
year of education results in 23.8551*(60) = 1431.306 fewer minutes of
working per week. The p-value of educ = 0.017 < 0.05
=> The independent variable educ is statistically significant.
- The coefficient = 262.6089 shows that: with other factors fixed, a person
with a good health has results in 262.6089*(60) = 15756.534 more minutes of
working per week than the person who doesn’t have a good health. The p-value
of educ = 0.048 < 0.05
=> The independent variable gdhlth is statistically significant
- The p-value of marr = 0.540 > 0.05
=> The independent variable marr is statistically insignificant.

22


2. Checking and correcting problems of the model
a. Testing for heteroskedasticity
* Heteroskedasticity and its consequences
One of OLS assumptions is that Var (u | x1, …, xk) = σ2 . That is, the
variance of the error term is constant (Homoskedasticity). If the error terms do
not have constant variance, they are said to be heteroskedastic. Unlike
multicollinearity, heteroskedasticity violates assumptions of OLS model.
Heteroskedasticity has serious consequences for the OLS estimator.
Although the OLS estimator remains unbiased, the estimated standard error is
wrong. Because of this, confidence intervals and hypotheses tests cannot be
relied on. In addition, the OLS estimator is no longer BLUE.
* Causes of heteroskedasticity



Due to the nature of economic phenomena: If the economic phenomena in
space is investigated in subjects with different size or economic
phenomenon to be investigated over time through the stages with the

different fluctuation, error variance can be uneven.
 Do not format correctly functional form of the model. Maybe omissions
appropriate variable or function analysis is wrong.
 Since the data does not reflect the nature of economic phenomena, such as
the appearance of foreign observers. The inclusion or exclusion of this
observation greatly influenced regression analysis.
 Because technical collection, preservation and processing of data should
be improved, error tends to decrease.
 Human learned in the past.
* Diagnosis
To test the changes of variance, we have the following hypothesis below:
where Ho are null hypothesis and H1 is alternative hypothesis
There are 2 different methods to test if the model is suffered from
heteroskedasticity or not:
 Method 1: White test
23


We use the command imtest, white for testing:
 Method 2: Breusch-Pagan‘s testing

We have a pair of hypothesis:
We use the command: xttest3
. xttest3
Modified Wald test for groupwise heteroskedasticity

in fixed effect regression model
H0: sigma(i)^2 = sigma^2 for all i
chi2 (239) =
Prob>chi2 =

3.1e+35
0.0000

Prob>chi2 = 0.0000 < 0.05 Reject the null hypothesis. The fixed effects model
has heteroskedasticity.
To fix the heteroskedasticity, we use the command robust
. xtreg totwrk educ gdhlth marr, fe robust
Fixed-effects (within) regression
Group variable: ID

Number of obs
Number of groups

=
=

478
239

R-sq:

Obs per group: min =
avg =
max =


2
2.0
2

within = 0.0421
between = 0.0063
overall = 0.0163

corr(u_i, Xb)

F(3,238)
Prob > F

= -0.0587

=
=

39.27
0.0000

(Std. Err. adjusted for 239 clusters in ID)
Robust
Std. Err.

totwrk

Coef.

t


educ
gdhlth
marr
_cons

-23.85516
262.6089
103.3492
2081.878

2.22757
135.4624
160.3955
164.548

sigma_u
sigma_e
rho

794.63064
780.61827
.50889463

(fraction of variance due to u_i)

-10.71
1.94
0.64
12.65


a. Testing for multicollinearity
* Multicollinearity

and its Consequences.

24

P>|t|
0.000
0.054
0.520
0.000

[95% Conf. Interval]
-28.24343
-4.249465
-212.627
1757.721

-19.46689
529.4672
419.3253
2406.034


A good model is the model to achieve the characteristics of BLUE (best,
linear, unbiased, most effective). But in fact because of some mistakes, the
model cannot fully achieve the above properties. One of the problems affecting
the model is Multicollinearity. Though it violates no assumption of OLS model,

it affects the accuracy of estimates.
Multicollinearity is an error of the regression analysis model, occurs due to
high (but not perfect) correlation between two or more independent variables.
The consequences of multicollinearity is that it can increase the variance of
the coefficient estimates and make the estimates very sensitive to minor changes
in the model. The result is that the coefficient estimates are unstable and difficult
to interpret. Multicollinearity makes it more difficult to specify the correct
model.

* Causes of multicollinearity
It is caused by an inaccurate use of dummy variables
It’s caused by the conclusion of variable which is computed from other




variables in the data set
• Multicollinearity can also result from the repetition of the same kind
variable
• Generally occurs when the variables are highly correlated to each other.
* Diagnosis
There are two popular methods to test if the model suffers from
multicollinearity:
 Method 1: Use command corr to check for multicollinearity.
Using command corr is more popular than the other method.
If tindependent variables are strongly correlated with each other (r> 0.8), multicollinearity
occurs.
 Method 2: Use command vif (variance inflation factor)
Before using command vif, we must use the command reg
25



×