Skip to content

Commit

Permalink
Multi-line ptable_scatter_plotly (#260)
Browse files Browse the repository at this point in the history
* add keyword hide_f_block: bool | 'auto' to ptable_hists_plotly and ptable_scatter_plotly

- add y_axis_kwargs to ptable_hists_plotly for customizing y-axis
- add handling of empty row 7 to moving later rows up in periodic table plots
- move axis tick inside for better layout/less overlap with neighbor subplots

* ptable_scatter_plotly support multiple lines per element

- introduce ElemData type alias for readability
- update data parameter to accept both single and multiple lines per element.
- enhance hover text formatting to include line names for multi-line plots
- add logic to manage color assignments for multiple lines and improved legend handling
- update tests to cover new multi-line functionality and various input scenarios, including empty data and mixed types

* fix test

* fix     if color_vals and hasattr(color_vals, "__iter__"):
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
  • Loading branch information
janosh authored Dec 16, 2024
1 parent 706a73e commit 4ef9e17
Show file tree
Hide file tree
Showing 2 changed files with 303 additions and 69 deletions.
Loading

0 comments on commit 4ef9e17

Please # to comment.