Sided twin violins render boxplot whiskers incorrectly
还没有人认领这个 Issue。
- 主要语言
- Python
- 星标
- 18.8k
- 派生
- 2.8k
- 平均合并
- 16 小时 26 分钟
- 30 天内合并 PR
- 21
描述
Plotly version: 6.3.0
Follow-up to #1634 (never resolved).
When using sided (split) violins with box=dict(visible=True), the boxplot whiskers are drawn at the inner edge of each half-box, rather than being centered as in a normal boxplot.
This makes the left and right whiskers appear extremely close together, which creates significant visual confusion.
Example from #1634 (Advanced Violin Plot example with box=dict(visible=True)):
My reproduction:
Normal (non-sided) violins for comparison:
Plotly 6.1.2 (in my work):
Possible cause:
The boxplots may be internally split in half to fit each half-violin, shifting the “center” used for whisker rendering to the midpoint between the halves.
Possible solutions:
- Preferred: Render each half-boxplot with whiskers centered over its own half-violin.
- Alternative: Allow configurable spacing between the halves to reduce whisker overlap.
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
未指定源文件或测试。首先使用 box=dict(visible=True) 重现 Advanced Violin Plot 中的 sided-violin 示例,然后将其与普通 violin 和 Plotly 6.1.2 进行比较,同时跟踪分割 box 的渲染路径。完成的标准是每一半的 whisker 都能正确居中,且不会导致普通 violin 发生回归。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- python
- 领域
- data-visualization
- Issue 类型
- 缺陷
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 45/100