Docsity

Ejercicios de Regresión Lineal: Resolución de Conjuntos, Ejercicios de Econometría

Toggle sidebar
bg1
Solution to Problem Set 5
Exercise 1 Recall the identity 1=P0P:
(a) Show that ITP X X01X1X0P0is symmetric and idempotent.
InP X X01X1X0P00
=InP X X01X1X0P0so the matrix
is symmetric.
To show that it is idempotent,
InP X X01X1X0P0InPX X01X1X0P0
=In2P X X01X1X0P0+P X X01X1X0P0P X X01X1X0P0
=In2P X X01X1X0P0+P X X01X1X0P0
=InP X X01X1X0P0:
(b) Show that the matrix X(X01X)1X01is idempotent but not sym-
metric.
It is clear that X(X01X)1X0106=X(X01X)1X01:Moreover,
X(X01X)1X01X(X01X)1X01=X(X01X)1X01
so the matrix is idempotent.
Exercise 2 Recall the expression for ^
OLS
1from the partitioned regression the-
orem, ^
OLS
1= (X0
1MX2X1)1X0
1MX2y: Compute the variance of ^
OLS
1under
heteroskedasticity, E[""0jX] = 2
":
Proof. Since it can be easily shown that ^
OLS
1remains unbiased (Eh^
OLS
1i=
1)as long as E["jX] = 0;we have that
Vh^
OLS
1i=Eh^
OLS
1E^
OLS
1ih^
OLS
1E^
OLS
1i0
=E(X0
1MX2X1)1X0
1MX2E[""0jX]M0
X2X1(X0
1MX2X1)1
=2E(X0
1MX2X1)1X0
1MX2M0
X2X1(X0
1MX2X1)1:
Exercise 3 Consider the transformed model
P y =P X +P ";
ey=e
X +e"
where 1=P0Pand ey=Py ; e
X=P X and e"=P ". Consider an arbitrary
partition of e
X= [ e
X1;e
X2] = [P X1; P X2]:Derive an expression for ^
GLS
1from
the partitioned regression theorem.
1
pf3

Vista previa parcial del texto

¡Descarga Ejercicios de Regresión Lineal: Resolución de Conjuntos y más Ejercicios en PDF de Econometría solo en Docsity!

Solution to Problem Set 5

Exercise 1 Recall the identity ^1 = P 0 P:

(a) Show that IT P X

X

0 1 X

X

0 P 0 is symmetric and idempotent.  In P X

X

0 1 X

X

0 P 0

= In P X

X

0 1 X

X

0 P 0 so the matrix

is symmetric.

To show that it is idempotent,

 In P X

X

0 1 X

X

0 P 0

In P X

X

0 1 X

X

0 P 0

= In 2 P X

X

0 1 X

X

0 P 0

  • P X

X

0 1 X

X

0 P 0 P X

X

0 1 X

X

0 P 0

= In 2 P X

X

0 1 X

X

0 P 0

  • P X

X

0 1 X

X

0 P 0

= In P X

X

0 1 X

X

0 P 0 :

(b) Show that the matrix X(X 0 1 X) 1 X 0 1 is idempotent but not sym-

metric.

It is clear that

X(X

0 1 X) 1 X 0 1

= X(X

0 1 X) 1 X 0 1 : Moreover,

X(X

0 1 X) 1 X 0 1 X(X 0 1 X) 1 X 0 1 = X(X 0 1 X) 1 X 0 1

so the matrix is idempotent.

Exercise 2 Recall the expression for ^^

OLS 1 from the partitioned regression the-

orem, ^^

OLS 1 = (X

0 1 MX 2 X^1 )

1 X^01 MX 2 y: Compute the variance of ^^

OLS 1 under heteroskedasticity, E [""^0 jX] = ^2 " :

Proof. Since it can be easily shown that ^^

OLS 1 remains unbiased (E

h ^

OLS 1

i

1 )^ as long as^ E^ ["jX] = 0;^ we have that

V

h ^

OLS 1

i = E

h ^

OLS 1 ^ E

^

OLS 1

i h ^

OLS 1 ^ E

^

OLS 1

i 0

= E

(X

0 1 MX 2 X^1 )

1 X 0 1 MX 2 E^ [""

0 jX] M 0 X 2 X^1 (X

0 1 MX 2 X^1 )

1

2 E

(X

0 1 MX 2 X^1 )

1 X 0 1 MX 2 M^

0 X 2 X^1 (X

0 1 MX 2 X^1 )

1

Exercise 3 Consider the transformed model

P y = P X + P ";

ey = Xe + e"

where 1 = P 0 P and ey = P y; Xe = P X and e" = P ". Consider an arbitrary

partition of Xe = [ Xe 1 ; Xe 2 ] = [P X 1 ; P X 2 ] : Derive an expression for ^^

GLS 1 from

the partitioned regression theorem.

Proof. We know from the partitioned regression theorem that

^

X~^0

1 M^ Xe 2

X^ ~

1

Xe^0 1 M^ Xe 2 ey

X

0 1 P^

0 M (^) Xe 2

P X 1

X

0 1 P^

0 M (^) Xe 2 P y

X

0 1 P^

0

In P X 2

X

0 2

1 X 2

X

0 2 P^

0

P X 1

X

0 1 P^

0

In P X 2

X

0 2

1 X 2

X

0 2 P^

0

P y

X

0 1

1 X 1 X 1 1 X 2

X

0 2

1 X 2

X

0 2

1 X 1

X

0 1

1 y X 1 1 X 2

X

0 2

1 X 2

Xx 1 y

since M (^) Xe 2 = In Xe 2

Xe^0 2 Xe 2

Xe^0 2 =^ In^ ^ P X^2

X

0 2

1 X 2

X

0 2 P^

0 :

Exercise 4 Consider the standard linear regression model y = X + " with

all classical assumptions holding and E [""^0 jX] = ^2 ". Consider the case of

measurement error in y: Instead of y you observe y^ = y +; where  

0 ; ^2  

is independent from X and ": Is the ^^

OLS unbiased? Compute its variance.

Proof. The OLS ^^

OLS = (X^0 X)

1 X^0 y^ = (X^0 X)

1 X^0 y + (X^0 X)

1 X^0 :

Taking expectation, we have

E

h ^ OLS i = E

h (X 0 X)

1 X 0 y

i

  • E

h (X 0 X)

1 X 0 

i

= + E

h (X 0 X)

1 X 0 "

i

  • E

h (X 0 X)

1 X 0 

i

= + E

h (X 0 X)

1 X 0 E ["jX]

i

  • E

h (X 0 X)

1 X 0 E [jX]

i

So, as long as E [jX] = 0; ^^

OLS is unbiased. To compute the variance,

V

h ^ OLS i = E

h ^ OLS E^^

OLS i h ^ OLS E^^

OLS i 0

= E

h (X 0 X)

1 X 0 " + (X 0 X)

1 X 0 

i h (X 0 X)

1 X 0 " + (X 0 X)

1 X 0 

i 0

2 "E

h (X 0 X)

1 X 0 X (X 0 X)

1

i

  •  2  E

h (X 0 X)

1 X 0 X (X 0 X)

1

i

since E [" 0 jX] = E [" 0 jX] = 0 as long as  and " are independent.

Exercise 5 Small simulation exercise. Suppose the DGP is yi = xi + "i with

= f 0 ; 0 : 05 ; 0 : 5 ; 2 g: Generate 1000 samples for "i from N

2 i

with  2 i =

0 :1 + sin (2 (i=n))

2 and xi from N (0; vi) with vi = 0:1 + (cos (2 (i=n)))

2 for

the sample sizes n = f 100 ; 500 ; 1000 g :

(a) In each case, estimate ^^

OLS and ^^

GLS (using the true values for  2 i as

known) and report size and power of the test = 0 for (i) ^^

OLS ignoring the