Skip to content
This repository was archived by the owner on Jun 3, 2024. It is now read-only.

express plots with "categories" in legend #151

Closed
K0ertis opened this issue Oct 15, 2019 · 1 comment
Closed

express plots with "categories" in legend #151

K0ertis opened this issue Oct 15, 2019 · 1 comment

Comments

@K0ertis
Copy link

K0ertis commented Oct 15, 2019

Hi!

I plot pandas dataframe with a "lot" of data

fig = px.line(df,
                x='time [s]',
                y="data [V]",
                line_group="group",
                color='pixel',
                line_dash='group',
                facet_col="int_times [µs]",
                facet_row="gain [1]"
                )

group has 4 elements and pixel has 64 elements which results to a legend which has 256 entries. Would it be possible to just add the type of the legend, like

  • pixel [1:64] -> 64 colors
  • line _group [1:4]
    dash -> group0
    dot -> group1
    dash-> group2
    longdash->group3

So in total there are 68 elements instead of 256, and each data is accessible by clicking to the right pixel/linestyle

@nicolaskruchten
Copy link
Contributor

This is a good idea which will be implemented once plotly/plotly.js#5099 is implemented, so I'll close as duplicate for now.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants