logarit của GDP thực tế theo ngang giá sức mua (lngdp), đo lường bằng đô la quốc tế cố định ở mức giá năm 2021
Biến quản trị
Kiểm soát tham nhũng (cc), ổn định chính trị (pv), tiếng nói và trách nhiệm giải trình (va)
Biến kiểm soát
Đầu tư trực tiếp nước ngoài (fdi), tổng vốn hình thành (gcapf), tiêu dùng chính phủ (gcons) và độ mở thương mại (trad). Tất cả đều tính theo tỷ lệ phần trăm GDP.
Biến giả
Biến giả thu nhập (inc): 0 (thu nhập trung bình thấp) và 1 (thu nhập trung bình cao). (Nước có thu nhập trung bình thấp: 52, nước có thu nhập trung bình cao:56)
Biến giả vùng: Sub–Saharan Africa (ssa), the Middle East and North Africa (mena), South Asia (sa), Latin America (la), Central Asia (ca), East Asia and the Pacific (eap)
Tải dữ liệu
library(tidyverse)
── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ──
✔ dplyr 1.1.4 ✔ readr 2.1.5
✔ forcats 1.0.0 ✔ stringr 1.5.1
✔ ggplot2 3.5.1 ✔ tibble 3.2.1
✔ lubridate 1.9.3 ✔ tidyr 1.3.1
✔ purrr 1.0.2
── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
✖ dplyr::filter() masks stats::filter()
✖ dplyr::lag() masks stats::lag()
ℹ Use the conflicted package (<http://conflicted.r-lib.org/>) to force all conflicts to become errors
library(plm)
Attaching package: 'plm'
The following objects are masked from 'package:dplyr':
between, lag, lead
Sử dụng mô hình POOLED OLS chỉ với các biến định lượng
Pooled1 <-lm(lngdp~fdi+gcapf+gcons+trad+va+pv+cc, data = Pdata)
car::vif(Pooled1)
fdi gcapf gcons trad va pv cc
1.007318 1.201217 1.532778 1.397588 2.408183 3.082034 3.093205
Không có hiện tượng đa cộng tuyến
Kiểm định có ảnh hưởng cá nhân, thời gian
Pooled <-plm(reg,Pdata, model="pooling" )plmtest(Pooled)
Lagrange Multiplier Test - (Honda)
data: reg
normal = 32.92, p-value < 2.2e-16
alternative hypothesis: significant effects
plmtest(Pooled, effect ="individual")
Lagrange Multiplier Test - (Honda)
data: reg
normal = 32.92, p-value < 2.2e-16
alternative hypothesis: significant effects
plmtest(Pooled, effect ="time")
Lagrange Multiplier Test - time effects (Honda)
data: reg
normal = -1.9806, p-value = 0.9762
alternative hypothesis: significant effects
plmtest(Pooled, effect ="twoway")
Lagrange Multiplier Test - two-ways effects (Honda)
data: reg
normal = 21.878, p-value < 2.2e-16
alternative hypothesis: significant effects
pwtest(Pooled,effect ="individual")
Wooldridge's test for unobserved individual effects
data: formula
z = 5.8152, p-value = 6.055e-09
alternative hypothesis: unobserved effect
pwtest(Pooled,effect ="time")
Wooldridge's test for unobserved time effects
data: formula
z = -2.8259, p-value = 0.004715
alternative hypothesis: unobserved effect
pwtest(Pooled,effect =c("individual", "time"))
Wooldridge's test for unobserved individual effects
data: formula
z = 5.8152, p-value = 6.055e-09
alternative hypothesis: unobserved effect
=> Có đặc trưng riêng, nên mô hình Pooled OLS không phù hợp
Kiểm định FEM & REM
phtest(FEM1, REM1)
Hausman Test
data: reg
chisq = 12.278, df = 7, p-value = 0.09178
alternative hypothesis: one model is inconsistent
Mô hình REM tốt hơn
Kiểm định tương quan chuỗi
library(lmtest)
Loading required package: zoo
Attaching package: 'zoo'
The following objects are masked from 'package:base':
as.Date, as.Date.numeric
bgtest(REM1)
Breusch-Godfrey test for serial correlation of order up to 1
data: REM1
LM test = 405.6, df = 1, p-value < 2.2e-16
Có hiện tượng tự tương quan bậc 1
Kiểm định phương sai sai số thay đổi
lmtest::bptest(REM1)
studentized Breusch-Pagan test
data: REM1
BP = 79.831, df = 14, p-value = 3.041e-11
Có hiện tượng phương sai sai số thay đổi
Kiểm định phụ thuộc chéo
pcdtest(REM1)
Warning in pcdres(tres = tres, n = n, w = w, form = paste(deparse(x$formula)),
: Some pairs of individuals (23 percent) do not have any or just one time
period in common and have been omitted from calculation
Pesaran CD test for cross-sectional dependence in panels
data: lngdp ~ inc + eap + ca + la + mena + sa + ssa + fdi + gcapf + gcons + trad + va + pv + cc
z = 1.6704, p-value = 0.09485
alternative hypothesis: cross-sectional dependence
Không có hiện tượng phụ thuộc chéo
Hiệu chỉnh sai số
model <- REM1coeftest(model)
t test of coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 7.83651627 1.72320805 4.5476 6.806e-06 ***
inc -0.01388216 0.38847955 -0.0357 0.971508
eap 2.57088316 1.67881857 1.5314 0.126308
ca 2.29168251 1.64732820 1.3912 0.164795
la 2.33667302 1.76468133 1.3241 0.186060
mena 2.26920439 1.72362967 1.3165 0.188597
sa 1.84502971 1.86936287 0.9870 0.324125
ssa 2.85630925 1.66217935 1.7184 0.086337 .
fdi -0.00032245 0.00138603 -0.2326 0.816132
gcapf -0.02576579 0.00796826 -3.2336 0.001303 **
gcons -0.00108993 0.00556092 -0.1960 0.844690
trad -0.00051695 0.00248731 -0.2078 0.835441
va -0.32764960 0.24361599 -1.3449 0.179250
pv 0.07506964 0.18548640 0.4047 0.685857
cc 0.46290871 0.22746282 2.0351 0.042365 *
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
coeftest(model, vcovHC)
t test of coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 7.83651627 0.84820310 9.2390 < 2.2e-16 ***
inc -0.01388216 0.36902406 -0.0376 0.9700067
eap 2.57088316 0.67332122 3.8182 0.0001512 ***
ca 2.29168251 0.49658731 4.6149 4.999e-06 ***
la 2.33667302 0.86746033 2.6937 0.0073025 **
mena 2.26920439 0.80211124 2.8290 0.0048553 **
sa 1.84502971 0.71310957 2.5873 0.0099525 **
ssa 2.85630925 0.67152043 4.2535 2.510e-05 ***
fdi -0.00032245 0.00049807 -0.6474 0.5176638
gcapf -0.02576579 0.00856046 -3.0099 0.0027449 **
gcons -0.00108993 0.00737889 -0.1477 0.8826309
trad -0.00051695 0.00319401 -0.1619 0.8714880
va -0.32764960 0.36833219 -0.8895 0.3741332
pv 0.07506964 0.25624603 0.2930 0.7696741
cc 0.46290871 0.30926002 1.4968 0.1350655
---
Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1