Anteprima
Vedrai una selezione di 3 pagine su 6
Assignment 8 1 1 Pag. 1 Assignment 8 1 1 Pag. 2
Anteprima di 3 pagg. su 6.
Scarica il documento per vederlo tutto.
Assignment 8 1 1 Pag. 6
1 su 6
D/illustrazione/soddisfatti o rimborsati
Disdici quando
vuoi
Acquista con carta
o PayPal
Scarica i documenti
tutte le volte che vuoi
Estratto del documento

Estimate Std. Error t value Pr(>|t|)

(Intercept) 0.933896 0.394382 2.368 0.0195 *

x 0.027073 0.005328 5.081 1.42e-06 ***

---

Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Residual standard error: 1.287 on 118 degrees of freedom

Multiple R-squared: 0.1795, Adjusted R-squared: 0.1726

F-statistic: 25.82 on 1 and 118 DF, p-value: 1.423e-06

## Running the OLS, coefficients are constant across the sample

Least Squares Dummy Variable

The different household intercepts are modeled using dummy variables.

#fixed dummy

> z1 <-lm(l ~ x + factor(hh) - 1, data=liq)

> summary(z1) Call:

lm(formula = l ~ x + factor(hh) - 1, data = liq)

Residuals:

Min 1Q Median 3Q Max

-1.66785 -0.54868 -0.04939 0.55354 2.04799

Coefficients:

Estimate Std. Error t value Pr(>|t|)

x 0.02074 0.02091 0.992 0.3242

factor(hh)1 0.42199 1.23666 0.341 0.7338

factor(hh)2 3.28983 2.13807 1.539 0.1279

factor(hh)3 2.03885 1.29899 1.570 0.1205

factor(hh)4 -0.04206 1.76677 -0.024 0.9811

factor(hh)5 1.35361 1.66023 0.815 0.4173

factor(hh)6 2.23154 2.09174 1.067 0.2893

factor(hh)7 1.15479 2.22085 0.520 0.6045

factor(hh)8 1.89022 1.82165 1.038 0.3026

factor(hh)9 1.69977 1.08653 1.564 0.1217

factor(hh)10 0.13792 1.39953 0.099 0.9217

factor(hh)11 2.08666 1.59751 1.306 0.1953

factor(hh)12 3.32583 2.17439 1.530 0.1301

factor(hh)13 0.42660 1.30526 0.327 0.7447

factor(hh)14 2.01231 1.37218 1.467 0.1465

factor(hh)15 1.17111 2.02207 0.579 0.5641

factor(hh)16 0.65131 2.11591 0.308 0.7590

factor(hh)17 0.61402 1.23604 0.497 0.6207

factor(hh)18 1.52889 1.54745 0.988 0.3262

factor(hh)19 3.31083 1.35887 2.436 0.0171 *

factor(hh)20 1.32804 1.28584 1.033 0.3048

factor(hh)21 1.60542 1.83424 0.875 0.3841

factor(hh)22 0.42109 1.04698 0.402 0.6886

factor(hh)23 -0.75640 0.95010 -0.796 0.4283

factor(hh)24 2.29574 1.47317 1.558 0.1231

factor(hh)25 1.60669 1.22737 1.309 0.1943

factor(hh)26 1.27090 0.94340 1.347 0.1818

factor(hh)27 2.87945 1.34305 2.144 0.0351 *

factor(hh)28 0.24110 2.22152 0.109 0.9139

factor(hh)29 1.22742 0.90216 1.361 0.1775

factor(hh)30 -0.40464 2.11456 -0.191 0.8487

factor(hh)31 0.96733 2.05219 0.471 0.6387

factor(hh)32 2.00557 1.62621 1.233 0.2211

factor(hh)33 2.17390 0.91359 2.380 0.0197 *

factor(hh)34 0.35526 1.47703 0.241 0.8105

factor(hh)35 0.65333 2.05219 0.318 0.7511

factor(hh)36 0.04396 1.11401 0.039 0.9686

factor(hh)37 1.53936 1.90730 0.807 0.4220

factor(hh)38 2.66710 1.62099 1.645 0.1039

factor(hh)39 2.34282 2.12934 1.100 0.2746

factor(hh)40 1.47991 1.99132 0.743 0.4596

---

Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Residual standard error: 0.9819 on 79 degrees of freedom

Multiple R-squared: 0.9371, Adjusted R-squared: 0.9045

F-statistic: 28.71 on 41 and 79 DF, p-value: < 2.2e-16

## we have a specific constant for each statistical unit. It captures its specific characteristic, fixed

across time.

Fixed Effects Estimator

Model: Within

> z2 <- plm(l~x, model=”within”, data = liq)

## plm is a package for R which intends to make the estimation of linear panel models. It provides

functions to estimate a wide variety of models and to make (robust) inference.

> summary(z2, robust = FALSE)

Oneway (individual) effect Within Model

Call:

plm(formula = l ~ x, data = liq, model = “within”)

Balanced Panel: n = 40, T = 3, N = 120

Residuals:

Min. 1 Qu. Median 3 Qu. Max.

st rd

-1.667853 -0.548685 -0.049386 0.553542 2.047993

Coefficients:

Estimate Std. Error t-value Pr(>|t|)

x 0.020742 0.020908 0.9921 0.3242

Total Sum of Squares: 77.107

Residual Sum of Squares: 76.159

R-Squared: 0.012305

Adj. R-Squared: -0.48779

F-statistic: 0.984166 on 1 and 79 DF, p-value: 0.3242

Model: Between

Only average data are available, averaged over the three years.

> z3 <- plm(l~x, model="between", data = liq)

> summary(z3, robust = FALSE)

Oneway (individual) effect Between Model

Call:

plm(formula = l ~ x, data = liq, model = "between")

Balanced Panel: n = 40, T = 3, N = 120

Observations used in estimation: 40

Residuals:

Min. 1st Qu. Median 3rd Qu. Max.

-1.962009 -0.845070 0.070112 0.700949 2.005886

Coefficients:

Estimate Std. Error t-value Pr(>|t|)

(Intercept) 0.9163337 0.5524439 1.6587 0.1054111

x 0.0273213 0.0074764 3.6544 0.0007757 ***

---

Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Total Sum of Squares: 53.741

Residual Sum of Squares: 39.766

R-Squared: 0.26004

Adj. R-Squared: 0.24057

F-statistic: 13.3544 on 1 and 38 DF, p-value: 0.00077572

Model: Random Effects Model

model the intercepts α were considered to be “fixed” parameters. In the random

In the fixed-effects

effects model we assume that all individual differences are captured by the intercept parameters,

but we also recognize that the individuals in our sample were randomly selected, and thus we treat

the individual differences as random rather than fixed.

The β and variance σ 2

are random drawings with mean

1i 1

> z4 <- plm(l~x, model="random", data = liq)

> summary(z4, robust = FALSE)

Oneway (individual) effect Random Effect Model

(Swamy-Arora's transformation)

Call:

plm(formula = l ~ x, data = liq, model = "random")

Balanced Panel: n = 40, T = 3, N = 120

Effects:

var std.dev share

idiosyncratic 0.9640 0.9819 0.571

individual 0.7251 0.8515 0.429

theta: 0.4459

Residuals:

Min. 1st Qu. Median 3rd Qu. Max.

-2.263634 -0.697383 0.078697 0.552680 2.225798

Coefficients:

Estimate Std. Error z-value Pr(>|z|)

(Intercept) 0.9690324 0.5210052 1.8599 0.0628957 .

x 0.0265755 0.0070126 3.7897 0.0001508 ***

---

Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Total Sum of Squares: 126.61

Residual Sum of Squares: 112.88

R-Squared: 0.1085

Adj. R-Squared: 0.10095

Chisq: 14.3618 on 1 DF, p-value: 0.00015083

Dettagli
A.A. 2024-2025
6 pagine
SSD Scienze economiche e statistiche SECS-P/05 Econometria

I contenuti di questa pagina costituiscono rielaborazioni personali del Publisher cristianoandreoli11 di informazioni apprese con la frequenza delle lezioni di Econometria e studio autonomo di eventuali libri di riferimento in preparazione dell'esame finale o della tesi. Non devono intendersi come materiale ufficiale dell'università Università Cattolica del "Sacro Cuore" o del prof Monticini Andrea.