plotly / plotly/plotly.js

Unclear Intended behavior for marker.size=0 for scatter and scattergl

未关闭
#6,862 0 条评论 0 个 reaction 已指派 1 人 在 GitHub 查看

@LiamConnors 已经在做这个了。

开始于 2024年7月12日。

bug P3
主要语言
JavaScript
星标
18.3k
派生
2k
平均合并
2 天 12 小时
30 天内合并 PR
28

描述

Setting the marker size to zero could have two reasonable interpretations:

  1. 0 is a valid input and the markers don't get plotted
  2. 0 is not a valid input and the markers get plotted in the default size

It seems Option 2 is the current implementation as of v2.28.0 (codepen link). But is that intentional? The documentation says

size
Parent: data[type=scattergl].marker
Type: number or array of numbers greater than or equal to 0
Default: 6
Sets the marker size(in px).

The documentation sounds a bit more like option 1, to me, because 0 is inside the valid range. Also, an array of all 0s does not get plotted, which I assumed should be the same behavior of a single 0.

Should the documentation be clarified or the implementation be changed?

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。