Skip to content

Parallel Coordinates do not fire on select event #2149

@khuesmann

Description

@khuesmann

Hi,
I would like to use the parallel coordinate visualization but i am struggling with making them interactive.
Here an example:

import plotly.graph_objects as go

fig = go.Figure(data=
    go.Parcoords(
        line_color='blue',
        dimensions = list([
            dict(range = [1,5],
                 constraintrange = [1,2], # change this range by dragging the pink line
                 label = 'A', values = [1,4]),
            dict(range = [1.5,5],
                 tickvals = [1.5,3,4.5],
                 label = 'B', values = [3,1.5]),
            dict(range = [1,5],
                 tickvals = [1,2,4,5],
                 label = 'C', values = [2,4],
                 ticktext = ['text 1', 'text 2', 'text 3', 'text 4']),
            dict(range = [1,5],
                 label = 'D', values = [4,2])
        ])
    )
)
fig.show()

def on_selection():
    print('hi')
    
fig.data[0].on_selection(on_selection)

Analogously to other plots i used the on_selection method. So when i am brushing an axis, i expect the on_selection method to fire, but it doesn't ... Am I doing something wrong or do I miss a special concept on Parcoords or is there a bug?

Thank you in advance!!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions