全部版块 我的主页
论坛 计量经济学与统计论坛 五区 计量经济学与统计软件 Stata专版
976 2
2019-07-05
请问有人晓得这儿为啥要传入俩参数么?touse的作用是啥?
二维码

扫码加我 拉你入群

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

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

全部回复
2019-7-5 16:58:54
Passing arguments to Mata functions
In designing a subroutine, you have two paramount interests: how you get data into your subroutine and
how you get results back. You get data in by the values you pass as the arguments. For calcsum(),
we called the subroutine by coding
mata: calcsum("`varlist'", "`touse'")
After macro expansion, that line turned into something like
mata: calcsum("mpg", " 0001dc")
The 0001dc variable is a temporary variable created by the marksample command earlier in our
ado-file. mpg was the variable specified by the user. After expansion, the arguments were nothing
more than strings, and those strings were passed to calcsum().
二维码

扫码加我 拉你入群

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

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

2019-7-5 17:09:17
谢谢分享
二维码

扫码加我 拉你入群

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

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

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

说点什么

分享

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