Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature requests #56

Open
droodman opened this issue Mar 9, 2024 · 2 comments
Open

Feature requests #56

droodman opened this issue Mar 9, 2024 · 2 comments

Comments

@droodman
Copy link

droodman commented Mar 9, 2024

I'm adding support for this package to reghdfejl for Stata(!).

This leads me to a few comments;

  • It would be great if nlreg accepted the GLM offset argument.
  • Support for observation weights would also be great.
  • Is it possible for the fitted model to include a dof_fes field with the number of degrees of freedom consumed by the absorbed FE? FixedEffectModels has this.

Also, I think it shouldn't crash when passed a formula with no fe() terms.

@droodman droodman changed the title Missing features Feature requests Mar 9, 2024
@jmboehm
Copy link
Owner

jmboehm commented Mar 10, 2024

Thank you, I agree on all points. I should say however that the coming weeks are quite busy and I don't know whether I'll have time for FOSS development....

@droodman
Copy link
Author

droodman commented Mar 11, 2024

Understood. Perhaps it will inspire you when the time comes to try the latest reghdfejl, which does call GLFixedEffectModels. It can be installed with

net install reghdfejl, replace from(https://raw.github.com/droodman/reghdfejl/master)

Then you can do the third example in the ppmlhdfe help file:

use "http://fmwww.bc.edu/RePEc/bocode/e/EXAMPLE_TRADE_FTA_DATA" if category=="TOTAL", clear
egen imp = group(isoimp)
egen exp = group(isoexp)
ppmlhdfe trade fta, a(imp#year exp#year imp#exp) cluster(imp#exp)
reghdfejl trade fta, a(imp#year exp#year imp#exp) cluster(imp#exp) family(pois)

Here the runtimes are trivial. But in an example with ~10,000,000 observations, I found that using your package in this way halved run time.

(I still need to document the new functionality and make the regression output more appropriate, e.g., by showing the log likelihood.)

Right now the other two ppmlhdfe help file examples fail because of issues raised above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants