janosh / pymatviz

A toolkit for visualizations in materials informatics.
https://janosh.github.io/pymatviz
MIT License
156 stars 13 forks source link

Restore `ptable_hists` kwarg `anno_kwds` (or something similar) #199

Open janosh opened 1 week ago

janosh commented 1 week ago

@DanielYang59 re your comment

Previously the ptable_hists has symbol_kwargs and anno_kwds. In the new implementation, support for annotate is completely removed, as I would assume their functionality overlaps.

i just realized that the removal of anno_kwds caused some issues over in matbench-discovery/data/mp/eda_mp_trj.py#L162 as mentioned in https://github.com/janosh/matbench-discovery/pull/130#discussion_r1733749688. do you remember what you meant by symbol_kwargs overlaps with anno_kwds. i don't think one can replace the other. this is the output with and without anno_kwds. maybe in this case the figure is overplotted with those histogram count annotations but in principle, i think the feature is nice to have (though perhaps with a better name)

Screenshot 2024-09-05 at 16 29 26

DanielYang59 commented 1 week ago

do you remember what you meant by symbol_kwargs overlaps with anno_kwds. i don't think one can replace the other.

Ah okay. I originally thought there would not be a use case where one need to add additional text (annotate) on top of the chemical symbol (because for the nested histogram, and other nested plots in general, has been quite informative/noisy already). But looks like that is a valid use case, so let's add it back :)