0% found this document useful (0 votes)
28 views33 pages

Econometrics Notes, University of Ghana

Uploaded by

Joy Newsair
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
28 views33 pages

Econometrics Notes, University of Ghana

Uploaded by

Joy Newsair
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 33

Caleb Ziblim

Econometrics I
2023
University of Ghana
Introduction
Pi + B2Ki stochastic
dependent
> no
varichte
y y
-
=
-

variable B + Periter Stochastic


independent
> -

2 =

y
-

Simple regression model

⑨: +
B +
o
wa = 0

abnat interp.
Variest
Shope
Coffcut

using
-
OLS
;
Bo E t
y
=
-

51 =

Enigi =
& (x -

m) Ly j)
-

En ; 2 2(n -

i) 2

Example
N

3
Y
in y
-

5
Engi 4

2
-

5 O 0 O
2

7
6 2
j 4 8

E(n -) =
0
Elz-5) =
0 Enigi 4
(n-rs2 = o =

i 5 6
y
= =

Zi =
B1 = 0

Yo B n 6
j 0 5(5)
: -

,
=
- .

= 3 .
5
-
-M

: Bo + P n

y
=
,

3 5 + 0 5m
y
=
.
.

TSS RSS Ely-y)2


2
=
z(y j) -

= = Seei
Ess 2

&(j j)
= -

Caleb Z
11 and should be unrelated
always
-
in

line
- a
larger intercept (BO) Sifts the
regression upwards
intercept cuts the below the
a
negative y
atis in atis
~

when B , =
0 it is a horizontal line
S
P1 Line
large Steeper regression
-
=

Objective of regression analysis


O G establis thes relations p
if a

O forecast new value

finaling wa

-2 how well
Fells
regression line
predicte actual des
a
us
-

22 distance the actual the


-

Compares the stwon value to men

2 the value to the


estimated mean

r
G(j j
=
= =
-

z(y
-

yjz
01 r 2 /

it w = 0
-
> no re l a t i o n s
p

we = m Perget relationslip

Examquestion : If
any of
the assumptions fail
,
will we

be able to estimate te
parameters ?

Variance Estimators
of
Exam question : WhatCondition Can the variance be heteroskedstic ?

spread
it is
hint ; about the
Eg
.
a
highy unequal population

=
VarLu) = 02

~ Parameters
no .
Of
-Ge
var (B ) .
=

Ep

Excu
question
.
When can the variance
of , be
large ?
Hint when variance is
; the e r ro r
larg
-
ie
. Var(B , ) = G2
-

2 (ni =

n)2

Sum residuals must be o


of

add
Why do we the e r ro r term ?

0 Omittel variables

① factor onlinearities
⑦ Measurement Errors

⑦ Unpredictable effects

Linearity In
Simple regression
9 Must be knear in variable

y=
B + Bex
, + e - near bes 23/2n = 32
B Pante > ha Sos My/on 2
Pa
y
-

=
.
+ =

= B + Be "n + e - c m kd dos Islan Ba/m "

y
-

,
=
,

Unear the is constant


means
stope
With Linear variables can knear but
regression /
be n on pracemeters
must always be linear .

Linearity
.
3
in Parameters
=
B, + B2x +
- >
Liner in
Parameters
y
u

y =
B ,
+ Pzm + m -
>
nonlinear in Parameters
Properties of regression
line

0 It through he in
i
sample means <
passes of
=F
-

O mean
value
of
actual ↑ d estimated Y a re
equal ie

=
residuals
Zeti
Mean va l e is 0 ie 0 0
of =

Assumptions of Classic Linear


Regression Model

O Model linear
parameters
in
is

& Thre has to be


variability in the Sample (n)
regressor
⑤ The va r i a n c e
of each mi is constant/homoscedetic
# There is no autocorrelation ston 2 a r r ow terms it. random

⑤ The model specified


regression
is
crrety Specifiction bies
.
i e .
no

including
-
not an
including an

important
i r r e ve r t

variabi varidie

I
~
makes the ols
Estimator biasel !!?

(source has
of
bas
depends on the
relationsp
the ommtil varidle with u

Unbiasedness os
of estimators

Y = B + Pen + u
,
-

:
2(x - i)
(y -

5) = E(x - m) [CP .
+ Pan + uS -

(1 ,
+ Ban +
in)]
San-a)
=
[Pala-n) + Leu-e)]
= BrELn-5] +
[In-5) (ee-tes
M

B2 = =
Be E (ni -2) + &(ai -

i) (ei -

i)
2 (oi -)2
Be
> 0
= B2 + E(mi - ) ( e e)
-
Since Eccl = o

E(mi -
n jm

Da =
Beautier

Gauss-Markov Theorem

States that the Ols estimator is BLUE (Best Unear Unbiase Estimated

if If
the holds
;
a It is a lineer function (in Parameters)
6) It is unbiased in Elise) = Be

6) It has a minimum variance in the class


of
allSuch Linea

nubiava Estimators -

.
Note Var (eci) = 02

==
wohre or

,
Ver (Bel
=
this implies Not
;

O the the variation in the smaller the Bed vice


larger
w
use
variance
,
of
O the ord the
larger the ,
larger the va r i a n c e
of
Be

The logn
the
Sample Size
,
he mor
varility in i a the
Bm is
m o re accurate

Caleb Z
iss = Ess + RSS

Ely -j(z z(j y(2 Ely - y)2


=
-
+

R=
1 =
#has to be variation in m

02
= =
Varie) =

Var(s)
=

sections the
er e r ro r variance (2) the
larger he va r i e
a
5
① The (El-5(2)
larger the
variability in ni the Smaller te

variance
of
Bi

Se()
==
Multipla near
regression
Bo + B, + Bene Blak + e
y = ms . .

The independent variables not be Lie Collinearity)


-

must related .
.
multi

Matrix to
finding
Gegficients
approach
P = (n'n) +
my
+
var/cuB = 0 (n'n)

[ corpais]
I Var B CovBiBe CovB , By

Lov Be B , Var Be

GovB3 Bi CovPbP2 Var B3

of =
where it

Example

·3
5

g
I 9

10 I+men te

B = In')Y
-
-
-

= ↓
3 12 x1 I I

Y
2 I I

12 8 9
Y
I 8

I 7 14 6 8
-

5 I 9 7

g g
-- -
I L
-

I'ml"
i win, adj
= + (22)

[2 [ &
(n'n) (m'2)"

I
5 46 485

=5
0 956 0

a
- .
- .

46 0 .
088 0-029

166 0 485
-

0 029 0 042
.

-
-

Caleb Z
[ii]
is =

154

[s405 &
P (2)
my
=
0 956
-

=
.

-0 .

Soling Maticus with Gluctor

Steps :

↓ Mode -
> Matrix-1 Wat A

② selet dimension first matric (3 + 3)


of
③ Press and
Input numbers and
Shift 4
① Select Data
⑤ Mat is and
repeat 2
⑧ Press AC

②Shift & 4
⑧ Select Mat A add
operation
a select Mat B

& Press 1
=
1

iI(j) 2
=

: ] [s 120 ] [i]
= 24 +
=
+ 1s

(2 + 1) + (1 + 4) + (2 + 3) 2 + 4 + 6

[ J i
Using Carc A B =
;

12
R2
1-
R" =
- -
Adjusta
= 1 =

Broscrea in M ESS
Things to ease
note
; -
R2 will increase when another
independent variable is added
-

This makes R22 unreliable


-

If added the
parameter estimates
unnecessary variables a re
,

remain Same
he

If
importat variable exclued,
an is the wo u l
parameters
-

be bissel .

Hypothesis testing

Additional assumption;
The er ror term is
normally distributed with a mean
of o
variance
ot
of

O Testing whether individual


Gefficients a re
different from
/equal to
D

hy
-
State auth a alternate potes's

Ho Pi Hi :
Bi > ch i ld fort
-

:
=
P 0

We're
testing to Check
if the Coefficients are
Significantly different
from 0 . This means the
independent variable influences to

depecht varichte

Find
-

Calculates t valu

=
teal
-

Find Critical t values

↓ crit
tin-
= or terit = ta n-k
,

& - to be tet

2 tale
+ st

Decision Rule

if It call > Itcrit) -


>
Ho
reject
if It cal 1 2 Itcrit >
-

Ho
accept

if (Itall Harity) it
rejetH o the
deficits
we >
means
I
are
Significat and Tur is a linear relation sp won
mid
y

Note : P
Any %, insignificant
is
value > 10 means
Coefficient
.

Confidence Interval

x =
=SecEs-margin
nex +

of
aro-

where Seli Starti


Fra
= =

② Testing if begricet is to Constant


equt a

State alternate
hypotees
-

null d

B
a .
Ch T2
Ho : , = al H1 : B aa

Conat at

Find Glalete + values

take

=is
a
-
find Critian + values

-crit farit to
+
= n - k or = n-k
, ,

Decision Rule
-

if It call > Itcrit) -


>
Ho
reject
if It call Itcrit -
> Ho
accept

if (Italc) B ai
we
accept
Ho < Itcrizh) it meance
=

③ Testing if Coefficit is
eque
to a parameter ; (linear Combinating
State null alternate
hypothes
-

&

Ho : Bi = Pr H1 : B1 + Be

find Glalete +

=
t calc

31 -

Be

find Initial t

twit =
ty ,
n-k or to ,
nuk

Decision Rule

if It call > Itcrit) -


>
Ho
reject
if It cal 1 2 Itcrit >
-

Ho
accept

This is used to test for constant returns to sale

Caleb Z
SelB -Bal
finding ,

var(B 1
-

B2) = Var(P1) + Var(B2) -


2 Cor (B , Ba)

SeLii-Bel JSelB
Selpe-
12)
2
= . ) +
,

④ Testing Exclusion Restrictions

g test is as & 24 have no


eyet so that we
only
know whether to include them or not

state alternate
by pothesis
-

nul a

Ho : By = By = 0 Hi : By = p

Means the 417 moded C


Old mode is in valid
is Valid

Using
f test Calculatet h e Falc
-

sch of restricted

-
feala :
-SSR)/@noo reviations

ur/n-Q
I T Of
Sa
of Parameters
Unrestrictel

-titled
Unrestriea

+ meas + 4424 + u

SSR this is SScur


of

Po + B 2 + Bere +e
y
= , ,

- >

SSR Of Mis is SSRr


-

Final Critical F values

Feriz = F2 n K
g ,
-

Decision Rule

if Falc Farit
> -
>
Reject Ho

Fal < Fart >


-
Accept Ho

⑤ Testing for Overall


Significence
used to
jointly test if all the
Stope Deficients a re
el to o

State alternate
hypoless
-

null d

Ho : B1 = B2 .
. .
.
BK =
w

Bo B Panz B3x3
given ; yi
= + , x + + + e

Men
;
Ho :
B
,
= Bz = Bz = 0 It i . Bit 0

find Calacatel F

Faceb
Tin -
1)

final Critical F

Frit = Fa k -
1 n -
1
, ,

Decision Rule
-

if Falc Farit
> -
>
Reject Ho

Fal < Fart >


-
Accept Ho
Example
sonhotansthis paints (Sjnfica gitia) - T +

5) Overall I
Synigence -
> tot

PRF :
On +
Born + u

N
Taxing for tis individuly
we use i to t

>
Ho : B2 By -
tot for
Spigene
= = 0 our

Ya
Hi Br B + 0

Ho

H1
:

:
inctively
R > o
-> Tony for
goodness of
fo

for
Testing individua
Significance of
B1 & Be does not mean that the

RF
overall is
Significant
· for individual 2 F for
we need to Conduct T tot
Signifiance Not

Import Previous
Overall
Synigiance GDP am Prices Import

d
accrry
-
Price

age
Se =
=

10
1

.
.
073

797)
+ 5 .

(0
20 .
812)
/ 20 .

111
+ 0 .
054me

10 22)
.
+ 0 .
045M2
20
G
.

019)
R2 = 0 .

934 als

t = 30

⑦ Interprete the results

Interprete all the


Geggaints & R2
0 1 .
073

When all the variables the Per


independent a re o
, anyage wage
entlogee is 1 .

073 units

① 5 .
288

VE =
unfilled Job
vacanc
: If
unfilled Job by
Vanary increases a unit
,
the the
Aug
Wages will increase
by 5 . 288
holdy or
independent various

Justar t

Same for other variates


indepecht
-

interpretation
.

22 =
0 .

934
Means that 93 4 % totch variation in
dependent vari at i on is
of
.

effend by the
independent variation in the model

⑤ Which the
Significat
which
begicets
estimatel and
a re
o
of
the various a re
dropped .

Note that
If deggicist is
insigigiant , cop variable
.

any

+ tex ; Be
Using Since we
k n ow is Patie

for

o
Be

Ho : B2 = 0 H .: Ba & O

Calculated
- =

E-0
=

Critic + = +c n-k = to .
os 30 - 5 =
to os 25 = 1 .
708
, , ,

Clearly ,
Calculated t > Critic t

: We Ho
reject
and hence Bo
,
is
statistically Sigrigct

Caleb Z
② What is the rationale
of using import
Prices in the mode !

Mt < M+ a re
import price
-1

Because , increase prices with Go


living which
import
in increase of

world
put pressure on
wages
to increase . Hace there is a
positive
relationship betwn wases >
import price
-

2) Tea for overall


signifiance the model .

of
we need R2 < N(t)

Sochi
-

R2 = 0 .

934 k = 5

n = 30

Ho
-
·

R = 0 Hi : r2 > o

=
dini /4
=
clacate = = 8

Critian F = F005(K-1) (n-k) = 7005(4 25) =

, ,

Glaldel F > Critian F

: We
rejet
the mor
hypotes's
fit
Hence
,
model is
Statistically Significant and thes a
good

Incremental/Marginal Contribution
of
an
explanatory variable
T is to m e a s u re n ow diffect the model is when a new

model)
independente variable is added (ie it becomes a re a c t e d

We use He F test here


,
sch of restricted

-
faala =
-SSR)/@noo reviations

ur/n-Q
I &
roof
SSR
Of Parameters
Unrestrictel
or

We Can use is" When it is


given

Falante = (Reno-RE)/g
41 -)/(n
&
- R u
-

k)

Same F Critical =
Fr(q ,
n - )

bi
a R2 de not makeh e mode m o re rich . Boss

models with m o re indevout Variables the RP is bond to be higher


,

"

:. in
We can non
adjusted
R2
As s
= 1 -

1-
Adjustd RE (2) =

R2
1 /
- =ll-
: =
or

"
i can be
negative
-

Note
:

for
a 2 va r i c u e
regression
modul
, testing the

inclivich
Significance of Gefficients is
enough
aral tot for
Ovec'synificance is not relevant
Testing equality of
2
regression Geggicients (Convent returns)

P + Pede + Bynx + Byx4 +

y
= . ei

Ho
were
tating if
B3
:
By =
B4 or -

B4 = 0

I
It 13
+ By Or 33 B + = 0
-

ie. if
Were
checking the
Greggicients of 23 & My a re
equal
+ test
Using ;

En
Calculated + test -

Calculated + = <B - 4)
-

Se < 13 -

By)

: +
a 4)

critical t =

t ,
n +

is4)
firling Se
J
n

Selig - ) = arciss P4) -

= ↓ Variss + var By-2 Cris Esy)


,

M
Example
141 76 + 63 472 12 962
2
9343
y
= . .

.
- .
+ 0 .

(6 37)
.

(4 .
77) 20 98) .
10 .

05)
Gr(3 4) ,
= 0 .

0576
R2 =
0 .

9983 n = w

TestIf e

need ofaddintheLudictermt
there is
any
is Es = By · is is
=> Ho : By- By =
0

4. : By -
By 0

io- 34
+=
Clatel

4) Swanse + varix -

20 15
,
84)
= ~
12 .

96 -
0 -

93 =
-

13 .

3/

J(0 .

902 + 0 .

052) -
- 0 .

0576

A critical n

t
=
,
Caleb Z

Dummy Variables

The a re used to test the


impact of qualitative variables or

Variables
quantitative
.

>
dependent
.

variable
quanitative
-

i
.
e

Independent- qualitative variable

dummy varidre takes the value


of 0 20
S &
Other wher observation has
wise
the devic character

Eg .
male 2 female

E
Di = & = Mate

0 = otherwise (females

Education lauch :

No education & = me ice]

We
only inclu Q- I dummies in the model
regression
The Omitted Category / is the intercept
number
of Categories
ie.
One
Category is left out .

The left
Category out is the
reference/base ategory
The base be
Category can
category
-

any
.

Exampleeffect
-

of gender on
Earnings
Bo B
Earnings = + , Gender + B2
Experience
but because Gender is
qualitative ,
we use
dummy variables

-Gender has female


categories Make
2 : .
e a

un-1
So
dummy
I
we use
-

We can either
gender
-

use
Bo
Earnings B2E +
P,
: = + Male 2) +

where

=
I
-

I I
? =
i I
n

y
=

33
10 I

for Parameters
after soling
12
;

Earrings of
a female : Po +
Pexp
Earrings Po P1 P2
+
a male : + Exp
of

Interpretation of
dummies
;
B is sturn female
difference
the the male and
earnings
-

, a
of
a

with the same led


of experience
base when
Always make to the
category interpreting
-

reference
Alternative Interpretation : Maly the lbor market ecorm
-

in

B (orless than females in the Sama market with


negativel
, m o re
g

the same back


experience
-

Always ferform Significant a tet on the


Gefficients first
.

Generating b dummies

Eduction Level : No eduction - > D ,

Pretertiary -
> D

Tertiary 13
-
>

butSince In-1) clumin have to


can
only use
we we
,

exclude one
Category [ no eduction is our basa
group here)
- Our
Regression moder
;
By
Earnings Bo + P
Pretertiary Batertiary Exp +
+ + e
= ,

Pretenting & trticy-1 G


petaithe difference stun the
earingings Stwn Geome with

education (bace
Pretertiary education and someone with no

group

: B2 is the
difference stun he
earnings of
someone with

election
tertiary education I someone with no (bace
groups

Note O u r :

results won't be
different if we use discont bace

groups
.

Exam question
!
Why do we include n-1 dummies when we have

?
n
Categories
Hint : We include n-1 dummies because including dummies will let
a
from
fall
dummy and his
the will
us into variable trap prevent us

the because
estimating coefficients including all dummies will

result in
perfect Golliverity .

This
Dummy varible trap : is when
you
include the same number
of
dummies as
categories .

Example 2

Earnings
= Po + B , Gender +
P2Pretertiary +
Potertiary
+ B42 +
p
+ ea

Reference/base : Females with no education


group
Since makes
we r e
using

Bo P
females with eduction
Earrings + +
Exp
i

no =
. e .

Males with Pretertiary a females wit no eduction :


Earnings =
Po +
B1 + Be + B + E+
P

Always Compare reac ts to


reference group

Caleb Z
Important use
of dummy variables

for for
-
Test the
Stability of Gefficients/testing Structura
Charge

Stabily of Gegents ;
Looking whter stoble time
ot Gefficients a re ove r

. We have 2 Prices in
Begora & After
both Periods
-Create
dummy
a fo r

We for Eructurch
test
change
can in
;
a

Both &
Slope Change
in
tercept
a

3
Only sope change
.

Only change
.
2
in
tercept

-
Base
Po
1

--

-Af te r

Hence for Prod 1 D = 0


,

Period 2
,
B =

Using te show test

Bo P,
Begin
+ + en - >
= r
2
.

y
= do + dim + e After
we need to find out
if
Pu = 20 and i, =
a

Lind Fadily chows


the using ze s t
;
to

Ho : Bo = - / B1 = ca

It :
Bo & puF 22
Testing Structura
Change/StaI LEy

Testing digrut Periods


-

Genficants
2
if a re ove r the

- >
Sa = Bo +, Y + u 1990 - 2000

th > 2001 2020


47 +
-

57 a
-

= 20 +
,

Introduce
during digmentiate
to btwn Period 1 & 2
-

Hand
Estime or e
equation
for bot Periods (merge
-

and introduce the


clummy

Represet (1990-2000) by
-
L (2001 -
20201
by
! Janmug
-
Introduce a
Contact
damy &
Shope damny I
for both
you'retacting

+
St Po B 47 22Diz
&
=
+ C , D + + u
,

whx = 0 & 22 = 0

both (no
change
the
periods a re
equal
st r u c t u r a l

Take I from unrestricted model


Note

for chummins
,
the
beggcets a re alled differential Stope Cogjcets
If Produced >
hypothes
mull
reject
-

55 Prac
8 if < = and = 0 .

09 193)

Puce > & .: We


accept null

Introducing the Kategories


~

same number dummies as with an


of
intercept present in the model , there will be ex a c t linear re l a t i o n s

(ie
among
regressors
. Multicoline -

ty) .

Multicollinarity prevents from


estimating
the begficants
-

us

its is kown
dummy variable
trap
-

as the .

If want to introduce some number chimmies as categories ,


you of
drop the intercept
Caleb Z

Model Errors
Specification
ky assumption
is that the mode is
Gorety Specifie ;
-

c Mode doesn't exclude core /relect varide


any
.

.
5 Doe not Include i r re l eva t va r i a b l e

.
2
Functional from va r i a b l e Switchy
is Chosen
of
2) No er ror
of measurent in
Legressor/Regressand
e .
Free of others in mode

f .

Eror ter m is al 10 22
,

Nonstochastic *
S
.

for Errors
-

checking specification

00mitting Gre vc r i e b e s

models here a re said to be under fitzel

d : -Lack data
maybe
to
of
-

Cardlessness

Lack
of Prope research
-

2 +
-

Po B +
Be By ddu +
Earnings
+
+ e
Age
+
= ,
p

it researcher estimate :

-
acruings
= Po + P ,
Age + BeSX10 + en Croedeation
S
W
nocht.
undersize

consequences depend on whath the a relations p Aton

the excluded variables a


Included various .

ie . Covariances stwn varises = 0


or o

If exchele variable is Grrelated to include


varid,
The estimated varibes w i ll be biased
Geggicient of
This bias does not clssepear as N
gets Urge
be
beygiants
-

will also inconsistent

-
If exclded variables a re not Greeted with indibl

(5) would be base .


va r i e ste
, only the
intercept

The va r i a n c e e r ro r term would not


be properly
of
estimatel

This would head to estimation se


of
wrong of
the va r i a n c e s the executors and lead to
of

wrong hypothesis testing

Frecanty would also be


-

wrong
.

-
We can F test on
re st r i c t i o n to see exc h l d
use
if

Variables a re
important

ware Face = (Re -

RE)/ 2 om
ISSir-SSiar)/9
(1 -
RES/n -
1 SsRur/n- K

>
Whe H0 Be leaving Bu By
-

: &
= B 3 = 0 out

B2 + 0

Ramsey's Regression Specific Eror (RESET


When don't have iden the
tyie e r ro r
any
-

we of of
Po B, Be
earings +
Age +
Exper + e >
Original model
-

~ Procedure Crestricted mode


-

from E x i m a te Product the valus


mode
earings
-

, of
Reestimate the mode the
saunes/cubes
including
~

the estimatel value


of
Bo + B,
Age + B2 Exper + B3 earrins + B4 earrings + e

Earrings =

L
undestricte model
T model becomes the restricted mode which the
original
-

mode
generated in
Step
2 is the Unrestricted model

Specification
~ Eor
-
-
Ho : Mode 1 is C o r re t (Pa =
+ = 0)
# i moder - is not Greet

We can use the F test on restrictions to Solve for

Tis

Lagrange Multiplier Test


-

used whe we know the variables

Earnings = Bo + B , Age + BrE +


per
+ en but we exchell Educ

O from sairtel model find the RSS (Seil)


,

② If daimtel iss the excutel


model is
Greety Specified ,
a voide

Lacub sound that be bundete


Regresshe e r ro r for m
of
the included a
exclude varicles

Anxilay
-

regression

If
large
*

log anxilary regressionl follows


n
is
,
n + R Chi
square
with of quitie
qual regressors
⑤ If alaleted Chi is sitide
squeld greate
than
Chi Squarel, no

reject the Ho .

(ie .

Orgul model is not


briety specific)
② Including irrelevant varies

Adding irrelevat varies is


overfitty .

Includy irrelevant verishe ahes not


my get
model

Seficients
-
a re unbissel a Consistent

-
Error vari an ce is GreetlySpecial
-

Gagehance Interven 2
hypothesis tearing world be velid

neck Sid
-

⑤ functional
Specfaction o
form

Obs

Caleb Z

You might also like