tlamadon / bipartitepandas

Python tools for bipartite labor data
MIT License
4 stars 1 forks source link

BipartiteDataFrame Changes my category variables #16

Open MeilianZhang opened 1 month ago

MeilianZhang commented 1 month ago

Hi!

Thank you for providing this package. I encountered an issue when converting my DataFrame to a BipartiteDataFrame. Some of my categorical variables changed from binary values (0 and 1) to fractional values (0, 0.333, 0.5, 0.6666, and 1). When I subsequently used the BipartiteDataFrame in fecontrol_param to estimate the AKM model, I received an error because the n_unique_ids for some of my categorical variables returned None. The problematic category variable is Xit, which indicates that the same worker may have different values in different years.

Maryan

adamoppenheimer commented 2 weeks ago

Hi Maryan,

Sorry for the delay in getting back, but thank you for using BipartitePandas and PyTwoWay, and for reaching out!

I have also encountered issues with newer versions of certain packages, such as Pandas and NumPy, with BipartitePandas. Unfortunately I haven't had time to work on issues related to this package recently.

Could you please share your code to make it easier to diagnose the potential issue? It's hard for me to know what could be causing the issue without seeing your code.

Best, Adam