Documente Academic
Documente Profesional
Documente Cultură
MULTIPLĂ
1
Exemplu 1
2
Exemplu 2
Î
3
Forma generală a modelului
x11 x1k
y1 k
ε1
x2 x2
1
β1
Y = X = ε = β =
y
n
k ε n
xn xn βk
1
Y = Xβ +
ε
4
Forma generală a modelului
5
Ansamb
x11 x21 ... x 1 k
x x ... x
X = [x 1 ,x 2 ,...,x =] 12 22
∈kM (
2
.
k
.... .... .... .... ,n )k
x x
1n 2 n ... x kn
1
1
y1
y2
yn
6
Etapele realizării unui model de regresie
multiplă
I. Id 7
Etapele realizării unui model de regresie
multiplă
III. Es 8
Ipotezele modelului de regresie multiplă
1. 9
1. Forma funcţională: Y = Xβ + ε
• Ipoteza de linearitate nu este atât de restrictivă pe cât pare. Aceasta
se referă la felul în care parametrii intră în ecuaţie, nu neapărat la
relaţia între variabilele x şi y.
10
2.Media zero a erorilor: E(ε )=0
• Valoarea reală a lui Y, înregistrată pe baza datelor statistice,
este de regulă mai mare sau mai mică decât cea estimată.
11
3. Homoscedasticitatea: E(ε ε ’)=σ 2In
Daca
cov(ε1, ε1 ) cov(ε1, ε 2 ) ... cov(ε1, ε n ) σε2 0 ... 0
cov(ε 2 , ε1 ) cov(ε 2 , ε 2 ) ... cov(ε 2 , ε n ) 0 σ ε2 ... 0
Ω (ε ,ε ) = E (εε ' ) = = .
............... ............... ... ............... ... ... ... ...
cov(ε n , ε1 ) cov(ε n , ε 2 ) ... cov(ε n , ε n ) 0 0 2
... σ ε
12
5.Matricea X este de rang k
C
1, k
13
Estimarea parametrilor prin MCMMP
Minim
S ( βˆ ) = ∑ ie2 = ∑ ( yi −ˆ xβ k ki ∑
ˆ− x β ... − ˆ x− 2)β ( yi − βˆ=' xi ) 2 .
1 1 i 2 2 i
i i i
e1
n
e2
∑ (ei2=e ...e1 )2
S ( βˆ) = e
i =1
n ⋅ ' =
ee
en
β̂
βˆ ' X 'Y
14
Estimarea parametrilor prin MCMMP
βˆ
∂ S (βˆ ) [∂Y ' Y 2−ˆ β' X ' Y ˆ '+Xβ ' X ˆ ] β [ ˆ ' X ' ∂Xβ ˆ ] ˆ β
= 2 X 'Y = − + 2 X 'Y β 2 X '=X −
Derivîn
∂ βˆ ˆ ∂β ˆ ∂β
βˆ = ( X ' X )− 1 X 'Y.
∂ S ( βˆ ) ∂ 2 S(βˆ )
= −2 X ' Y +2 X ' X βˆ = 2 X' X
∂ βˆ ˆ ˆ
∂β ∂β '
β̂
15
Interpretarea parametrilor
Pentru
yi = βˆ1 x1i + βˆ2 x2i+ ...+ β k ˆ kix.
∆y i = βˆ1 ∆x1i ,
β1
ˆ ∆y i
β1 = .
∆x1i
modelul
β̂1
16
Forma echivalentă de estimare a parametrilor
S ( βˆ ) = ∑ e = ∑ ( y − βˆ x
i
2
i
i
i 1 1i − βˆ2 x2i − ... − βˆk xki ) 2 = ∑( y
i
i
ˆ ' x )2 .
−β i
.......................................................................
βˆ1 ∑ x1i x pi + βˆ2 ∑ x2i x pi + ... + βˆ k ∑ x ki = ∑ y ix ki
2
i i i i
∑ex
i
i 1i ∑ eix 2i = 0,...,∑ eixki = 0.
= 0,
i i
17
Modele particulare
Caz
1, p
18
Între p
β j = β* j ;
σy
βj = β** j .
σ xi
zt = yt − y şi u jt = x jt − x j ;
yt − y x jt − x j
Zt = si u jt = .
σy σj
σj
19
Coeficienţii de corelaţie parţială
Prin mry / xi =
cov( y, xi ) =
cov( y, xi )
σ y σ xi
∑y
t
n
t xit
rxi / x j =
cov(xi , x j )
cov(xi , x j ) =
∑ yt x jt = n cov( y, xi )
t
σ xi σ xj
∑x x
t
n
.
it jt
.
∑ xit x jt = n cov( xi , x j ).
t
20
Luând în
nσ x21 cov(
n 1 ,x 2 x) ... cov(
n 1, x x)k
n cov( x , x ) σ 2
xn ... n cov( x2 k , x )
X 'X = 2 1 2
n [ 1 2 C ] kx =,x
................... .................... ....................
..
n cov( kx ,1 x ) n cov( kx , 2x ) ... σ 2 n xk
cov(y, x1 )
X'y = n = nC[ y, X] ,
cov(y, x p )
Vectoru
yˆ = Xβˆ = X( X' X)-1 X' y.
[ ] [ ]
T r( G ) = T rI − X( X' X )−1 X' = T r( I ) − T r X( X' X )−1 X' = n − k ;
GX ' = 0
P = I - G, ˆy = Py ;
PX = X( X' X) −1 X' X = X
PG = GP = 0.
β̂
β̂ = Ly
Propr
L = ( X' X) −1 X'∈ M (1,n);
23
[( )] [ ]
Propr
)(
Var (βˆ ) = Ωβˆ = E β − βˆ β − βˆ ' = E ( X' X ) −1 X' εε ' X( X' X ) −1 =
cov(βˆ , e) = 0.
e'e ∑t
e 2
σˆ ε2 = = t σ ε2
n −k n −k
σˆ = σˆε ( X ' X ) .
-1
Var ( βˆ )
2 2
βˆ
24
Coeficientul de determinaţie R2
• Este o măsură a proporţiei varianţei explicate de model
n n
SSR ∑ ( ˆ
y i − y ) 2
∑ ei
2
R2 = = i =1 = −
1 =i 1
∈2 [0,1 ]
SST
• R2 este afectat de ∑ ( yi −numărului
creşterea
i
y) 2
∑de
i
( yi − y)
parametri; de
aceea pentru modele cu multi parametri se calculează
R2 ajustat, care are aceeaşi interpretare.
n−1 n 1−
R = 1 −(1 − R )
2 2
1∈ − ,1
n − k
adj
n k−
25
Tabelul ANOVA
Source
n SSR MSR
SSR = ∑ (Yˆi − Y ) 2
k −1 MSE
i =1
n SSE
SSE = ∑
e 2
i =1
i
n−k
n SST
SST = ∑ ( iY − Y) 2
n −1
i =1
H
θ ii =
ˆ
βi → N β,i σε ( X'X) ii
−1
βi − βˆi
zi = → N(0,1).
σε ( X'X ) −1
ii
27
Pentru
σˆ = σ ( X'X ) ii .
2 −1 2
βˆi e
βˆi − βi
ti =
σe ( X ' X ) ii
−1
β i − tα / 2; −n k σe ( X'X) ii
( eσ )X'X ii
−1 1−
ˆ ≤ βi ≤ ˆβi +t
/α2; n −k
28
Exemplu
• O firmă vrea sa evalueze impactul publicităţii în
radio şi presa scrisă asupra vînzărilor produselor
sale. Sînt luate în calcul 3 variabile:
• Y – valoarea vînzărilor(mii dolari)
• X1- cheltuielile cu publicitatea prin radio(mii dolari)
• X2 - cheltuielile cu publicitatea prin presa scrisă(mii
dolari)
• Sînt înregistrate, timp de o lună, valorile acestor 3
variabile în 22 de oraşe, aproximativ omogene din
punctul de vedere al comportamentului
consumatorilor.
29
-Modelul de regresie:
Sales =β 0
ε+
+ β 1 Radio+ β 2 Newspaper
30
Corelograma 3D
31
Rezultatul regresiei
32
Matricea X
33
Matricile X’X si X’X -1
34
METODA CELOR MAI MICI PATRATE
35
Exemplu
36
Exemplu
37
38