全部版块 我的主页
论坛 计量经济学与统计论坛 五区 计量经济学与统计软件 Stata专版
3660 3
2008-07-03

 use "D:\计量经济学\计量Work\劳动力市场分割\slm.dta", clear

. do "C:\Documents and Settings\Administrator\桌面\switch.do"

.
. program define switch
  1. args lnf W P S sig13 sig11 sig23 sig22
  2. quietly replace `lnf'=(1-norm((-`W'-(`sig13'/`sig11')*($ML_y1-`P'))/((1-(`sig13'^2/`sig11'))^.5)))
  3. *dnorm(($ML_y1-`P')/`sig11'^.5)*(1/`sig11'^.5)+(norm((-`W'-(`sig23'/`sig22')*($ML_y2-`S'))/((1-(`sig23'
> ^2/`sig22'))^.5))
. *dnorm(($ML_y2-`S')/`sig22'^.5)*(1/`sig22'^.5))
. quietly replace `lnf'=ln(`lnf')
  4. end

.
end of do-file

. ml model lf switch (sep:  Guesprob  urban gender educ pdummy) (sa0:  lipyear  expe expe2 gender folk ed
> uc party)(sa1:  lipyear  expe expe2 gender folk educ party)

. ml max

Unknown function norm()
r(133);

. ml max,difficult

Unknown function norm()
r(133);

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2008-7-5 09:55:00
 ml max

Unknown function norm()
r(133);

之前的不是很明白,但是这个好象是说你的函数表达形式出了问题,或者说你的函数表达形式是STATA中是不承认的哦!

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2008-7-5 15:39:00

norm() should be  normal()

dnorm() should be   normalden()

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2010-10-31 13:10:33
果然是这样!
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群