Introduction To Econometrics (ET2013) : Teresa Randazzo
Introduction To Econometrics (ET2013) : Teresa Randazzo
Teresa Randazzo
(Introduction to Econometrics) 1
Contacts
I Email: teresa.randazzo@unive.it
I Room: A.005
(Introduction to Econometrics) 2
Organizational Details
I Timetable:
I Monday, 15:45-17:15, San Giobbe 8A
I Tuesday, 15:45-17:15, San Giobbe 8A
I Wednesday, 15:45-17:15, San Giobbe 5A
I Thursday, 08:45-9:15, San Giobbe 4A (Dr. Michele Costola)
I Prerequisites:
I Statistics
I Probability
(Introduction to Econometrics) 4
Econometrics
(Introduction to Econometrics) 5
Econometrics
(Introduction to Econometrics) 6
The structure of economic data
(Introduction to Econometrics) 7
Example # 1: Economic Model of Energy consumption
I Aim to explain energy consumption behaviour and to identify its
determinants.
I In economics the relationships between economic variables is
expressed using the mathematical concept of a function.
y = f (x1 x2 x3...)
where:
y = energy consumption
x1 = temperature
x2 = price index
x3 = income
x4 = ...
(Introduction to Econometrics) 8
Example # 2: Wage and background characteristics
I Question of interest: What is the effect of additional education on
earned wage?
I Economic model:
where:
y = observed hourly wage
x1 = age
x2 = gender
x3 = years of formal education
x4 = years of workforce experience
I Econometric model:
y = b0 + b1 x1 + b2 x2 + b3 x3 + b4 x4 + u
(Introduction to Econometrics) 9
Types of Data
I Cross-sectional data ara data on different entities (workers,
consumers, firms, governmental units, ecc.) for a single time
period. Most often cross-section data are data for micro units -
individuals, households, companies, etc. (e.g Household Budget
Survey for the year yyyy, the Manufacturing Statistics for the year
yyyy, the Population Census for the year yyyy)
I Time series data are data for a single entity (person, firm,
country) collected at multiple time periods. Most often
time-series data are macro data (e.g the Index of Manufacturing
Production, the Consumer Price Index and Financial statistics -
money stock, exchange rates, interest rates, bank deposits, etc.)
I Panel data, also called longitudinal data, are data for multiple
entities in which each entity is observed at two or more time
periods (e.g household consumptions over years, European
countries GDP growth)
(Introduction to Econometrics) 10
Course Outline
(Introduction to Econometrics) 11
Matrix Algebra
I Matrix definition
I Matrix Manipulation
I Properties of Matrices
(Introduction to Econometrics) 12
Matrix Algebra
Vectors
A vector is an ordered sequence of elements arranged in a row or
column
a1
a = a2 a0 = a1 a2 a3
a3
a1 b1
a = a2 b = b2
a3 b3
Addition and Substraction
a1 + b1
c = a + b a2 + b2
a3 + b3
(Introduction to Econometrics) 13
Matrix Algebra
Vectors
Vectors Multiplication
a1 ka1
a2 ka2
k ×a=
. . . = . . .
an kan
b1
n
b2
X
a’b = a1 a2 . . . an × . = a1 b1 +a2 b2 +...+an bn = ai bi = b’a
..
i=1
bn
n
X
a’a = ai2
i=1
(Introduction to Econometrics) 14
Matrix Algebra
Matrix
The order of a matrix is given by the number of rows and the number
of column
a11 a12 a13 a11 a21 a31
A = a21 a22 a23 A0 = a12 a22 a32
a31 a32 a33 a13 a23 a33
(Introduction to Econometrics) 15
Matrix Algebra
Matrix
Transpose properties
1 (A+B)’=A’+B’
2 (A × B)’=B’A’
3 (A × B × C)’=C’ B’ A’
4 (A’)’=A
(Introduction to Econometrics) 16
Matrix Algebra
Matrix Multiplication
A B = C
n×k k×s n×s
n
X
cij = aik bkj
k=1
1 6
1 2 3 4 11
AB = × 0 1 =
2 0 4 6 16
1 1
1 6 13 2 27
1 2 3
BA = 0 1 × =2 0 4
2 0 4
1 1 3 2 7
AB 6= BA
(Introduction to Econometrics) 17
Matrix Algebra
Square Matrices
The unit or identity matrix of order n × n is
1 0 ... 0
0 1 . . . 0
In = . .
.. .. . . ..
. .
0 0 ... 1
For a matrix A of order m × n Im A = AIn = A
Diagonal matrix
λ1 0 . . . 0
0 λ2 . . . 0
.. .. . . ..
. . . .
0 0 . . . λn
Idempotent Matrix
A = A2 = A3 = ...
(Introduction to Econometrics) 18
Matrix Algebra
Squared Matrix
An important property of the squared matrix is the trace which is the
sum of the elements on the principal diagonal, that is
X
tr (A) = aii
i
If the matrix A is of order m × n and B is of order n × m than AB
and BA are both squared matrix and tr(AB)=tr(BA)
rank(A) ≤ (m, n)
A Matrix has a full rank if
rank(A) = min(m, n)
(Introduction to Econometrics) 19
Matrix Algebra
Determinant
(Introduction to Econometrics) 20
Matrix Algebra
Inverse Matrix
C0 = adjA
1
A− 1 = adjA
|A|
(Introduction to Econometrics) 21
Matrix Algebra
Inverse Matrix
(A−1 )−1 = A
(Introduction to Econometrics) 22
Recall of Statistics and Probability
Random Variable
I A random variable (RV) is a variable whose value is unknown
until it is observed
I A RV is a numerical summary of a random outcome such that
each event (an event is a set of one or more outcomes) is
associated to a probability.
I A random variable that can only take the values zero and one is
called Bernoulli random variable
(Introduction to Econometrics) 24
Recall of Statistics and Probability
p.m.f. and c.d.f. of a discrete RV
F (x) = Pr (X ≤ x)
I If f is the probability mass function of a discrete random variable
X with range f (x1, x2, ...) and F is its cumulative distribution
function, then X
F (x) = f (xi )
x≤ x
(Introduction to Econometrics) 25
Recall of Statistics and Probability
p.m.f. and c.d.f. of a discrete RV
Roll of a fair dice
SampleSpace : S = {1, 2, 3, 4, 5, 6}
Because the die is fair, each of the six faces has an equally likely
I p.m.f
I c.d.f
1/6 x = 1
2/6 x = 2
3/6 x = 3
Pr [X ≤ x] = FX (x) =
4/6 x = 4
5/6 x = 5
6/6 x = 6
(Introduction to Econometrics) 26
Recall of Statistics and Probability
p.m.f. and c.d.f. of a continuous RV
(Introduction to Econometrics) 27
Recall of Statistics and Probability
p.m.f. and c.d.f. of a continuous RV
(Introduction to Econometrics) 28
Recall of Statistics and Probability
p.m.f. and c.d.f. of a continuous RV
(Introduction to Econometrics) 29
Recall of Statistics and Probability
p.m.f. and c.d.f. of a continuous RV
(Introduction to Econometrics) 30
Recall of Statistics and Probability
Joint probability distribution
(Introduction to Econometrics) 31
Recall of Statistics and Probability
Joint probability distribution
Let X and Y be two discrete RV, then (X,Y) have a joint distribution
that is described by the joint probability density function of (X,Y)
f (x, y ) = P(X = x, Y = y )
When the two variables are continuous, a joint p.d.f. can be defined as
f (x, y ) = f (x)f (y )
or Z b2 Z b1
f (a1 6 X 6 b1 , a2 6 Y 6 b2 ) = f (x, y )dxdy
a2 a1
(Introduction to Econometrics) 32
Recall of Statistics and Probability
Expected Value
When a distribution is symmetric around its mean the mean and the
median are identical!
(Introduction to Econometrics) 33
Recall of Statistics and Probability
Expected Value
Properties
I E(a)=a
I E(x+y)=E(x)+E(y)
I E(ax)=aE(x)
I E(ax+b)=aE(x)+b
(Introduction to Econometrics) 34
Recall of Statistics and Probability
Covariance
(Introduction to Econometrics) 35
Recall of Statistics and Probability
Variance
The variance of a random variable X, denoted var(X), is the expected
value of the square of the deviation of X from its mean:
Cov (XY )
ρ=
σx σy
Properties
I It has a value between +1 and -1
I Two variables are uncorrelated if ρ = 0
I Correlation does not need dipendence
(Introduction to Econometrics) 37
Recall of Statistics and Probability
Joint probability distribution
# Example
I Joint distribution:
P(X = 0, Y = 1) = 0.15
I Conditional distribution:
P(Y = 0|X = 0) = P(X = 0, Y = 0)/P(X = 0) =??
(Introduction to Econometrics) 38
Recall of Statistics and Probability
Conditional Distribution
Conditional expectation:
P
E (Y |X = x) = i=1 yi P(Y = yi |X = x)
Conditional variance:
var (Y |X = x) = i=1 [yi − E (Y |X = x)]2 P(Y = yi |X = x)
P
Properties
I E [E (Y |X )] = E (Y ) Law of iterated expectations
I E (aX + bZ |Y ) = aE (X |Y ) + bE (Z |Y )
I E (aX |X ) = aX
I E (X |Y ) = E (X ) is X and Y are independent
(Introduction to Econometrics) 39
Recall of Statistics and Probability
Conditional Distribution
Compute
I E (Y |X = 0)
I E (Y |X = 1)
I var (Y |X = 0)
(Introduction to Econometrics) 40
Recall of Statistics and Probability
Moments
(Introduction to Econometrics) 41
Recall of Statistics and Probability
Skewness
(Introduction to Econometrics) 42
Recall of Statistics and Probability
Skewness & Kurtosis
(Introduction to Econometrics) 43
Recall of Statistics and Probability
Kurtosis
The kurtosis of a distribution is a measure of how much mass is in its
tails and, therefore, is a measure of how much of the variance of Y
arises from extreme values
The greater the kurtosis of a distribution, the more likely are outliers
(extreme values)
E (X − µx )4
Kurtosis =
σx4
I Because E (X − µx )4 cannot be negative, the kurtosis cannot be
negative
I The kurtosis of a normally distributed random variable is 3
I A distribution with kurtosis exceeding 3 is called leptokurtic
I A distribution with kurtosis less than 3 is called platicurtic
I Like skewness, the kurtosis is unit free, so changing the units of X
does not change its kurtosis.
(Introduction to Econometrics) 44
Recall of Statistics and Probability
The Normal Distribution
The probability density function of a normally distributed random
variable (the normal p.d.f.) is
1 h 1 x − µ 2 i
x
f (x) = √ exp −
σ 2π 2 σ
(Introduction to Econometrics) 45
Recall of Statistics and Probability
The Standard Normal Distribution
Using the trasformation Z = X σ−µ we get the standard normal
distribution which is a normal distribution with mean µ = 0 and
variace σ 2 = 1
# Example:
Suppose X is distributed N(1,4). What is the probability that X ≤ 2?
(Introduction to Econometrics) 46
Recall of Statistics and Probability
The χ2 Distribution
The χ2 distribution is the distribution of the sum of m squared
independent standard normal random variables.
This distribution depends on m, which is called the degrees of freedom
of the chi-squared distribution
X ∼ (µ, σ 2 )
Z ∼ (0, 1)
Taking the square of Z we get Z = ( x−µ 2
σ ) . The sum of all values of
2
Z gives the χm2
X X X − µ 2
Z2 = = χ2
σ
(Introduction to Econometrics) 47
Recall of Statistics and Probability
The t Distribution
The Student t distribution with m degrees of freedom is the
distribution of the ratio of a standard normal random variable, divided
by the square root of an independently distributed chi-squared random
variable divided by m
Z
t(m) = q
χ2
m
(Introduction to Econometrics) 49