paulgp / bartik-weight

MIT License
67 stars 42 forks source link

Command in Stata reporting missing betas and alphas #8

Open wagfoliveira opened 2 years ago

wagfoliveira commented 2 years ago

Dear @paulgp,

Thank you very much for providing this wonderful resource. I have already implemented in a cross-section setting and everything worked pretty fine.

But I am having some trouble using the bartik_weight command in Stata with a panel dataset.

The structure of the data is very similar to the one of the BAR (canonical Bartik) example, I am only make the necessary adaptations in the replication code.

The issue is that the command is giving me missing betas and alphas. The code is not running into any error, but the resulting summary table does not have anything for the columns beta, alpha, gamma and pi.

Do you have any ideas on what might be causing this problem? Please let me know if you need more information/clarification.

Also, why the 'by(time_var)' option is not used in the BAR replication, since it is a panel? I also tried with it, but I get a conformability error.

Best, Wagner Oliveira PhD Candidate in Economics FGV EPGE

clowenstein commented 1 year ago

Dear @paulgp,

Thank you for making this super helpful resource available. I'm wondering if the issue @wagfoliveira described above is common and/or was ever resolved? I am also running the bartik_weight command in Stata in a panel setting (similar to the canonical Bartik) and getting missing values for beta, alpha, gamma, and pi. The by(time_var) option also yields a conformability error in my case.

Thank you again for this incredibly generous public good!

Chris Lowenstein Postdoctoral Researcher Stanford Center for Population Health Sciences

Umblijs commented 1 year ago

Dear @paulgp,

Thank you for making this great resource open access.

I am also having problems with running the bartik_weight command in a panel setting. My data is also very similar to the one of the BAR example, except that I have 16 years instead of two. When running it on my data alpha is only calculated for 4 years, the other years have a 0 value. Did you @wagfoliveira and @clowenstein manage to resolve the problem?

Regards

Janis Umblijs Senior Research Fellow Institute for Social Research Oslo, Norway