help regtable                                                     Version 3.0.0


regtable -- This command is designed to simplify visualizing subgroup analysis results from randomized experiments. The command outputs a table of conditional average treatment effects with corresponding standard errors across a subgroup variable.


regtable regtype depvar treatvar [if] [in] [weight] , group(groupvar) [vce(vcetype)] [covars(varlist)] [file(path)] [replace]

regtype type of regression (e.g., ols, logistic, poisson, etc.) depvar dependent variable treatvar treatment variable group(groupvar) name of the subgroup variable covars(varlist) list of control variables file(path) directory and file name (if unspecified the resulting table is saved as `regtype'_`depvar'_`treatvar'_across_`groupvar'_table.csv in the working directory) replace replaces the file, if it already exists


regtable creates a csv output file of conditional average treatment effects and corresponding standard errors for each category of a subgroup variable. The resulting file could then be used for the construction of subgroup analysis graphs using graphing and data visualization software outside of Stata.


. regtable reg y x, group(gender)

Saved Results The resulting table is saved in `regtype'_`depvar'_`treatvar'_across_`groupvar'_table.csv if the file option is left unspecified.


John Ternovski Analyst Institute