lucashusted / pystout

A Package To Make Publication Quality Latex Tables From Python Regression Output
GNU General Public License v3.0
42 stars 12 forks source link

This is fantastic. #1

Closed Econ808 closed 3 years ago

Econ808 commented 3 years ago

Please make some noise about this package! It has saved me so much time and pain.

There are other packages that attempt what you are doing, yet haven't managed to combine output from multiple statistical packages. It was only through a lucky Github follow that I actually stumbled upon this package, despite searching everywhere for a way to combining output from multiple regressions carried out by linearmodels.PanelOLS and statsmodels.OLS.

Of course certain things are not plug-and-play (yet), such as PanelOLS not including R-squared values, however, these can be included manually in the pystout function 👍

lucashusted commented 3 years ago

Hi @Econ808 I would love to make some more noise. I have a few other packages that help with Econ too that you can check out. Any ideas where to publicize it? Not sure exactly how to do that exactly.

Also thanks for your kind words.

Econ808 commented 3 years ago

Yeah, the best bet is probably to find issues that are unsolved, and mention that pystout might be the solution:

Otherwise you might want to write a "Medium" article about the package - they somehow always show up at the top of my google searches.

lucashusted commented 3 years ago

Thanks Tobias! I made your changes and uploaded the new version to pypi. I am down to keep working on this and other projects with you too. I have a package to calculate propensity scores and another one to do regression discontinuity in python (I cheat and ship it over to R). I've been meaning to modify statsmodels to more intelligently drop variables that are collinear like in stata so that I never have the urge to use Stata again, for example. Hit me up.

Econ808 commented 3 years ago

Yeah, I really hope that this slight push from R towards Python means that Python will be the preferred open-source statistical software. I am submitting my Master Thesis in two weeks, and I will not be working in a field where causality is a main focus (Data Science/ Business Intelligence), however, I might still find time to contribute.

In terms of enhancements to the python packages, you might want to open up issues to address these. In my pull request I changed the output such that a latex table instance was returned rather than the tabular instance. I am now doubting whether this unchangeable default is actually a good way to output the table, and that maybe a table instance should only be returned if a label or title is provided. Below a difference in how to create the same table (assuming label and title is provided in result_table and not result_tabular) using tabular and table, respectively:

image

image

lucashusted commented 3 years ago

I have made the changes for the newest version. The default is a tabular though a table is written if title or label are explicitly specified. You can update to version 0.0.5.

On Nov 16, 2020, at 4:01 AM, Tobias Ersted notifications@github.com wrote:

Yeah, I really hope that this slight push from R towards Python means that Python will be the preferred open-source statistical software. I am submitting my Master Thesis in two weeks, and I will not be working in a field where causality is a main focus (Data Science/ Business Intelligence), however, I might still find time to contribute.

In terms of enhancements to the python packages, you might want to open up issues to address these. In my pull request I changed the output such that a latex table instance was returned rather than the tabular instance. I am now doubting whether this unchangeable default is actually a good way to output the table, and that maybe a table instance should only be returned if a label or title is provided. Below a difference in how to create the same table (assuming label and title is provided in result_table and not result_tabular) using tabular and table, respectively:

https://user-images.githubusercontent.com/36441764/99232694-890f9200-27f2-11eb-9d53-12c406ac21c5.png https://user-images.githubusercontent.com/36441764/99232708-90cf3680-27f2-11eb-8842-1ada7e40eb26.png — You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/lucashusted/pystout/issues/1#issuecomment-727838353, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJPYYY63VTPGKIXYZCWEC3LSQDS57ANCNFSM4TUOY6SA.