-
Notifications
You must be signed in to change notification settings - Fork 16
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
New pandas.DataFrame.attrs
feature possibly useful for metadata such as root
or label
#236
Comments
I hope this is relevant to the discussion: something I noticed when working on #235 was that the
perhaps |
Regarding the TEX labels, these are not so much metadata of the entire dataframe, but, more precisely, each is connected to one corresponding column. As such I really like the current implementation. It also renders beautifully in jupyter notebooks!!! To get the Tex label of one specific column, this would be the suggested way: ns.get_label('x0') That said, it would be nice to have the sliced |
I believe so, e.g. calling |
Related to #253 |
Also related to #303 |
When reviewing #232, I initially got tripped up and did not notice the difference in the similar kwargs
label
andlabels
, and got worried that the same kwarg was being passed toMCMCSamples
orNestedSamples
. However, as it turns out they are different, one being the (tex) labels for the columns, the other being the label/name of the entire dataframe.I have come across a potentially interesting stackoverflow answer mentioning the
pandas.DataFrame.attrs
dictionary attribute (new as of pandas 1.5.0, note that it is flagged as "experimental"). This seems like the right place to put the remainders of our "metadata" to ensure the information persists even when copying/pickling/dropping/etc. What do you think?@williamjameshandley, do you know whether/how good anesthetic currently manages to retain the
label
attribute when copying/pickling/dropping/etc.?The text was updated successfully, but these errors were encountered: