独自学习事件研究法,遇到几个问题?
一,以普林斯顿大学event study研究为例,在完成了以下一系列动作后
………………
sort id date
by id: egen ar_sd = sd(abnormal_return)
gen test =(1/sqrt(5)) * ( cumulative_abnormal_return /ar_sd)
list company_id cumulative_abnormal_return test if dif==0
outsheet company_id event_date cumulative_abnormal_return test using stata.csv if dif==0, comma names
reg cumulative_abnormal_return if dif==0, robust
怎么样输出这样的图形:
请问需要什么样的stata命令才能得到以上的图形!!
二,在一篇文章中看到这样的分析:

,作者做了事件前后20天【-20,+20】,每天的AR值,T值,P值和CAR值,T值,P值。
我想问这个是一天天计算出来的;还是按照【-1,+1】,【-2,+2】……【—19,+19】,【—20,+20】这样计算出来的;有没有循环命令能够一次实现,谢谢指导!