Multinomial Logit
Teori Sederhana Multinomial Logit
Pengembangan dari
model logit dan probit yang sering digunakan untuk penelitian adalah
multinomial logit atau multinomial probit. Jika dalam permodelan logit dan
probit biasa kita hanya memiliki angka yang berisi 0 atau 1, maka di
multinomial ini berbeda angkanya 1, 2, 3..dst.
Sama seperti logit
probit, angka-angka yang dimasukan merupakan kata pengkatagorikan yang memiliki
kriteria atau range tertentu sesuai dengan penelitian yang kita inginkan.
Namun, menentukan derajat 1,2,3 .. dst di multinomial bukanlah mengartikan
urutan dimana 2 lebih baik dari pada 1 dan 3 lebih baik dari 2. Jika data yang
kita masukan merupakan 2 lebih baik dari pada 1 dan 3 lebih baik dari , maka
yang kita gunakan permodelan Ordered.
Secara mudah
Multinomial Logit dapat dirumuskan sebagai berikut:
Sementara
itu, dengan menggunakan persamaan diatas, kita bisa mencari juga probabilitas
relative. Missal mencari probabilitas relatis y = 2, maka maka
persamaannya menjadi seperti berikut:
Aplikasi di STATA
Diketahui bahwa variabel hours_cat memiliki nilai dan penjelasan sebagai berikut:
i). Jam
kerja di bawah normal antara 1-1819 jam setahun
ii). Jam
kerja normal antara 1820-2080 jam setahun sebagai referensi
iii) Jam
kerja di atas normal lebih dari 2080 jam per tahun.
Cara membuat variabel hours_cat:
gen
hours_cat=1 if hours<=1819
replace
hours_cat=2 if hours>=1820 & hours <=2080
replace hours_cat=3 if hours>=2081
tab
hours_cat
hours_cat | Freq.
Percent Cum.
------------+-----------------------------------
1
| 617 81.94 81.94
2 | 95 12.62 94.56
3 | 41 5.44 100.00
------------+-----------------------------------
Total | 753
100.00
Memberikan variabel lavel pada suatu
variabel, missal varabel hours_cat
label
values hours_cat ket
label
define ket 1 " K. Normal" 2 "Normal" 3 "A.Normal"
Sedangkan jika ingin melihat hasilnya:
tab hours_cat
jam2 | Freq.
Percent Cum.
------------+-----------------------------------
K. Normal | 617 81.94 81.94
Normal | 95 12.62 94.56
A.Normal | 41 5.44 100.00
------------+-----------------------------------
Total | 753
100.00
Misal hanya 2 variabel
mlogit hours_cat educ
Iteration
0: log likelihood = -438.90217
Iteration
1: log likelihood = -435.96827
Iteration
2: log likelihood = -435.93291
Iteration
3: log likelihood = -435.9329
Multinomial
logistic regression
Number of obs = 753
LR chi2(2) = 5.94
Prob > chi2 = 0.0513
Log
likelihood = -435.9329 Pseudo R2 =
0.0068
------------------------------------------------------------------------------
hours_cat | Coef.
Std. Err. z P>|z|
[95% Conf. Interval]
-------------+----------------------------------------------------------------
_K__Normal |
(base outcome)
-------------+----------------------------------------------------------------
Normal |
educ |
-.0773102 .0487177
-1.59 0.113 -.1727951
.0181746
_cons |
-.9351976 .5930384 -1.58
0.115 -2.097532 .2271363
-------------+----------------------------------------------------------------
A_Normal |
educ |
.1199565 .0705041
1.70 0.089 -.018229
.2581419
_cons |
-4.22436 .922681 -4.58
0.000 -6.032781 -2.415938
------------------------------------------------------------------------------
Maka penjelasan dengan matematisnya dapat digambarkan sebagai berikut:
Mendapatkan marginal
effects
untuk masing-masing persamaan.
Outcome =1
mfx, predict(p outcome(1))
Marginal
effects after mlogit
y
= Pr(hours_cat==_K__Normal) (predict, p outcome(1))
=
.82256326
------------------------------------------------------------------------------
variable
| dy/dx Std. Err. z
P>|z| [ 95% C.I.
] X
---------+--------------------------------------------------------------------
educ |
.0027551 .00597 0.46
0.645 -.008951 .014461
12.2869
------------------------------------------------------------------------------
Outcome =2
mfx, predict(p outcome(2))
Marginal
effects after mlogit
y
= Pr(hours_cat==Normal) (predict, p outcome(2))
=
.12487686
------------------------------------------------------------------------------
variable
| dy/dx Std. Err. z
P>|z| [ 95% C.I.
] X
---------+--------------------------------------------------------------------
educ |
-.009236 .00525 -1.76
0.079 -.019527 .001055
12.2869
------------------------------------------------------------------------------
Outcome =3
mfx, predict(p outcome(3))
Marginal
effects after mlogit
y
= Pr(hours_cat==A_Normal) (predict, p outcome(3))
=
.05255988
------------------------------------------------------------------------------
variable
| dy/dx Std. Err. z
P>|z| [ 95% C.I.
] X
---------+--------------------------------------------------------------------
educ |
.0064809 .00339 1.91
0.056 -.000155 .013117
12.2869
------------------------------------------------------------------------------
Mengestimasi mlogit dengan logit
gen hours1 =
hours_cat==1
gen hours2 =
hours_cat==2
gen hours3 = hours_cat==3
Hours1
logit hours1 educ
Iteration
0: log likelihood = -355.65586
Iteration
1: log likelihood = -355.56924
Iteration
2: log likelihood = -355.56923
Logistic
regression
Number of obs = 753
LR chi2(1) = 0.17
Prob > chi2 = 0.6772
Log
likelihood = -355.56923
Pseudo R2 = 0.0002
------------------------------------------------------------------------------
hours1 | Coef.
Std. Err. z P>|z|
[95% Conf. Interval]
-------------+----------------------------------------------------------------
educ |
.0173105 .0415954 0.42
0.677 -.064215 .098836
_cons |
1.300019 .5174371 2.51
0.012 .285861 2.314177
------------------------------------------------------------------------------
Hours2
logit hours2 educ
Iteration
0: log likelihood = -285.40597
Iteration
1: log likelihood = -283.88588
Iteration
2: log likelihood = -283.87813
Iteration
3: log likelihood = -283.87813
Logistic
regression
Number of obs = 753
LR
chi2(1) = 3.06
Prob > chi2 = 0.0805
Log
likelihood = -283.87813
Pseudo R2 = 0.0054
------------------------------------------------------------------------------
hours2 | Coef.
Std. Err. z P>|z|
[95% Conf. Interval]
-------------+----------------------------------------------------------------
educ |
-.0844493 .048436
-1.74 0.081 -.1793821
.0104835
_cons |
-.9114778 .5897666 -1.55
0.122 -2.067399 .2444434
------------------------------------------------------------------------------
Hours3
logit hours3 educ
Iteration
0: log likelihood = -159.19319
Iteration
1: log likelihood = -157.51826
Iteration
2: log likelihood = -157.48812
Iteration
3: log likelihood = -157.48811
Logistic
regression
Number of obs = 753
LR chi2(1) = 3.41
Prob > chi2 = 0.0648
Log
likelihood = -157.48811
Pseudo R2 = 0.0107
------------------------------------------------------------------------------
hours3 | Coef.
Std. Err. z P>|z|
[95% Conf. Interval]
-------------+----------------------------------------------------------------
educ |
.1297405 .0701374
1.85 0.064 -.0077263
.2672073
_cons |
-4.487523 .9180048 -4.89
0.000 -6.28678 -2.688267
------------------------------------------------------------------------------
Misal dengan menggunakan banyak variabel
mlogit hours_cat nwifeinc educ exper expersq age kidslt6 kidsge6
Iteration
0: log likelihood = -438.90217
Iteration
1: log likelihood = -386.93083
Iteration
2: log likelihood = -374.15512
Iteration
3: log likelihood = -373.39288
Iteration
4: log likelihood = -373.38458
Iteration
5: log likelihood = -373.38458
Multinomial
logistic regression
Number of obs = 753
LR chi2(14) = 131.04
Prob
> chi2 = 0.0000
Log
likelihood = -373.38458
Pseudo R2 = 0.1493
------------------------------------------------------------------------------
hours_cat | Coef.
Std. Err. z P>|z|
[95% Conf. Interval]
-------------+----------------------------------------------------------------
_K__Normal |
(base outcome)
-------------+----------------------------------------------------------------
Normal |
nwifeinc |
-.0225697 .0144235 -1.56
0.118 -.0508393 .0056998
educ |
-.0896376 .0568701 -1.58
0.115 -.201101 .0218258
exper |
.1683806 .0476524 3.53
0.000 .0749837 .2617775
expersq |
-.0020595 .0013793 -1.49
0.135 -.004763 .0006439
age |
-.0882005 .0197882 -4.46
0.000 -.1269845 -.0494164
kidslt6 |
-1.909118 .5200971 -3.67
0.000 -2.928489 -.8897463
kidsge6 |
-.1600934 .1052753 -1.52
0.128 -.3664293 .0462424
_cons |
2.165653 1.187548 1.82
0.068 -.161898 4.493203
-------------+----------------------------------------------------------------
A_Normal |
nwifeinc |
-.0087611 .0178409 -0.49
0.623 -.0437286 .0262064
educ |
.0990413 .0787529 1.26
0.209 -.0553114 .2533941
exper |
.1563197 .0663208 2.36
0.018 .0263334 .286306
expersq |
-.0006523 .0017247 -0.38
0.705 -.0040326 .002728
age |
-.0954166 .0299821 -3.18
0.001 -.1541804 -.0366527
kidslt6 |
-.7324912 .4359529 -1.68
0.093 -1.586943 .1219607
kidsge6 |
-.1187151 .1555571 -0.76
0.445 -.4236014 .1861712
_cons |
-1.375764 1.683735 -0.82
0.414 -4.675824 1.924297
------------------------------------------------------------------------------
Komentar
Posting Komentar