在第二讲数据处理里,您讲到过等分样本,命令是
sort wage
gen g_wage=group(5)
可是这个命令不能考虑进权重。请问如何可以将权重考虑进去来等分样本呢?比如一篇文献里的分组步骤:
The procedure first ranks children from lowest to highest according to the amount of equivalized earnings in each year. The samples in each year are then divided into 100 equally sized groups, taking household sampling weights into account.
假设变量名是:
income:家庭收入
num: 家庭人数
weight:家庭权重
是不是先sort income,然后如何再根据人数和权重(num*weight)分为100组呢(100 equally sized groups)?
非常感谢!!!


雷达卡






嘿嘿~谢谢鼓励~
京公网安备 11010802022788号







