plotly / plotly/plotly.py

Parallel plot: controlling angle and position behavior

Open
#5,182 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature P3
Dominant language
Python
Stars
18.8k
Forks
2.8k
Avg merge
16h 26m
Merged PRs (30d)
21

Description

Hi plotly team,

When the labelangle is below some threshold, the axis label gets centered automatically (like "choose_from(...)" on the figure below). Instead, we'd like to control this behavior with a parameter, so that long texts can fit the screen nicely, with a low angle and right alignment with the axis. WDYT?

Ideally, something like:

import plotly.graph_objects as go

go.Figure(
    go.Parcoords(
        dimensions=[
            {
                "label": "hello " * 5,
                "values": [1, 2, 4, 5],
            }
        ],
        labelangle=20,
        labelside="top",
        align_center=False, # <-- 
    )
)

Image

See: https://github.com/skrub-data/skrub/issues/1367

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the go.Parcoords entry point and inspect how labelangle and labelside are exposed and handled. Determine where the requested align_center behavior belongs, then add coverage showing that a low-angle label can retain the requested alignment without breaking existing defaults.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
data-visualization
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.