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 request: broom methods for fixest models #2

Closed
karldw opened this issue Nov 21, 2019 · 6 comments
Closed

Feature request: broom methods for fixest models #2

karldw opened this issue Nov 21, 2019 · 6 comments

Comments

@karldw
Copy link

karldw commented Nov 21, 2019

Thanks for the great package!

It would be convenient (for me, hopefully for others) if fixest had tidy.fixest, glance.fixest, and augment.fixest methods. The broom docs provide recommendations for adding these methods: https://broom.tidyverse.org/articles/adding-tidiers.html

library(broom)
library(fixest)

tidy(lm(mpg ~ wt, data=mtcars))
#> # A tibble: 2 x 5
#>   term        estimate std.error statistic  p.value
#>   <chr>          <dbl>     <dbl>     <dbl>    <dbl>
#> 1 (Intercept)    37.3      1.88      19.9  8.24e-19
#> 2 wt             -5.34     0.559     -9.56 1.29e-10
tidy(feols(mpg ~ wt, data=mtcars))
#> Error: No tidy method for objects of class fixest

Created on 2019-11-20 by the reprex package (v0.3.0)

What do you think?
If anyone else wants to tackle this, please feel free. If not, I can submit a PR sometime in the next few weeks.

@lrberge
Copy link
Owner

lrberge commented Nov 21, 2019

Thanks for your suggestion!

Actually I think the natural location of this implementation would be in the broom package rather than in fixest. The main reason is that I don't use tidyverse at all (and I'm not a tibble fan) and would like to keep the package as free as possible from imports and dependencies.

Yet for tidyverse users, your suggestion is of value and a very good idea. Would it be possible for you to write a PR for the broom package instead? Of course, I can help in the process if there are any requests in the objects returned by fixest.

@karldw
Copy link
Author

karldw commented Nov 21, 2019

Sounds good! I'll open an issue there.

@karldw
Copy link
Author

karldw commented Jan 14, 2020

@lrberge, it's not at all urgent, but would you consider another CRAN release in the next few months? The broom methods I wrote depend on some of the more recent changes (e.g. NA behavior in #3), and it would be nice to get them out into the world.

@lrberge
Copy link
Owner

lrberge commented Jan 15, 2020

You've done it, that's great! Thanks a lot!
Indeed, I'm planning to release a new version by the end of the month. Thanks again!

@lrberge
Copy link
Owner

lrberge commented Feb 1, 2020

Just to mention: I've just submitted to CRAN, it should be out soon!

@karldw
Copy link
Author

karldw commented Feb 3, 2020

Wonderful, thank you!

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