全部版块 我的主页
论坛 计量经济学与统计论坛 五区 计量经济学与统计软件 Stata专版
5587 6
2013-08-04
有一份数据,要求对每一个POLICY=1的样本找4个POLICY=0的配对样本满足YEAR SIC2 DP相同然后FS最接近,求出配对样本的MB  TA CHR 的,与样本进行比较,该怎么做呀,不知道数据格式有没有错误,看了之前voodoo的一些帖子回复,不明白呀,太笨了,求哥各位大身帮帮忙~
CUSIP是公司的代码

附件列表

sample.zip

大小:4.42 MB

 马上下载

本附件包括:

  • sample.dta

二维码

扫码加我 拉你入群

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

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

全部回复
2013-8-4 19:45:58
MB TA CHR 的 mean
二维码

扫码加我 拉你入群

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

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

2013-8-5 11:58:22
1. create two datasets from orignial dataset - dataset with policy =1 and dataset with policy = 0
2. use joinby to link all of possible matched observations
3. Check for the closest 4 observations based on FS
二维码

扫码加我 拉你入群

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

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

2013-8-5 19:38:43
ctx5518 发表于 2013-8-5 11:58
1. create two datasets from orignial dataset - dataset with policy =1 and dataset with policy = 0
2 ...
sorry, How to conduct the thrid step, I am a beginner for stata~
二维码

扫码加我 拉你入群

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

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

2013-8-6 08:37:40
1. When you create the two dataset, rename the FS and other variables to different name, for example FS to FS1 if policy  = 1, and do not need to change the matching variable name.
2. After the joinby, generate the difference between FS and FS1, you may take the absolute value for the difference
3. bysort  EAR SIC2 DP (difference): keep if _n == 4
二维码

扫码加我 拉你入群

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

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

2013-8-6 23:11:00
ctx5518 发表于 2013-8-6 08:37
1. When you create the two dataset, rename the FS and other variables to different name, for example ...
cheers~
二维码

扫码加我 拉你入群

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

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

点击查看更多内容…
相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

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