1 Star 0 Fork 11

唐志祥 / Stata-Event_Study

forked from 连享会 / Stata-Event_Study 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README

Stata

My Stata .ado files (and templates for starting a new Stata project).

event_study

Converts WRDS event study output to CARs.

fm

Returns Fama-MacBeth (1973) time-series average coefficients with Newey-West (1987) standard errors based. First-stage estimator can be regress, logit, logistic, probit, or tobit, but the code is easily modifiable to new estimators. Compatible with estout.

Examples

fm y x1 x2, lag(4)

fm d x1 x2, estimator(logit)

fm y x1 x2, estimator(tobit) options(ll(0) ul(1))

Tasks

  • help file
  • examples
  • standard output, like regress
  • all-in-one solution (takes 1st stage regression as a string)

log_transform

Log transform variable with variable label. Option to add arbitrary constant.

Examples

sysuse auto, clear
log_transform price
log_transform weight, add(1)

Tasks

  • help file
  • examples

peek

Peek at head and tail of not-in-memory data.

Examples

sysuse auto, clear
save auto, replace
peek using auto
peek price weight using auto

Tasks

  • help file
  • examples

rolling_beta

Quickly calculate rolling univariate regressions.

Examples

webuse grunfeld, clear
rolling_beta mvalue kstock, short(3) long(5)

Tasks

  • help file
  • examples
  • options for minimum # of observations

rolling_rho

Quickly perform rolling correlations.

Examples

webuse grunfeld, clear
rolling_rho mvalue kstock, short(3) long(5)

Tasks

  • help file
  • examples
  • options for minimum # of observations

rolling_sigma

Quickly perform rolling standard deviations.

Examples

webuse grunfeld, clear
rolling_sigma mvalue kstock, short(3) long(5)

Tasks

  • help file
  • examples
  • options for minimum # of observations

time_transform

Easy leads, lags, and differences with variable labels.

Examples

webuse grunfeld, clear
time_transform mvalue kstock, operators("S1" "L1" "L2")
time_transform invest, o("L2")

Tasks

  • help file
  • examples
  • options for minimum # of observations

WRDS

Simple .ado file wrapper for simple .py script to download data from WRDS. Save data as either .dta or .csv file. See https://github.com/wharton/wrds for more information on .py script.

Examples

TBD.

Tasks

  • help file
  • examples

空文件

简介

My Stata .ado and .do files 展开 收起
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
1
https://gitee.com/ahnutang_zhi_xiang/Stata-Event_Study.git
git@gitee.com:ahnutang_zhi_xiang/Stata-Event_Study.git
ahnutang_zhi_xiang
Stata-Event_Study
Stata-Event_Study
master

搜索帮助