plotly / plotly/plotly.js

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

Đang mở
#6,862 0 bình luận 0 reaction 1 người được giao Xem trên GitHub

@LiamConnors đang làm issue này rồi.

Từ ngày 12/7/2024.

bug P3
Ngôn ngữ chính
JavaScript
Star
18.3k
Fork
2k
Merge trung bình
2 ngày 12 giờ
Pull request đã merge (30 ngày)
28

Mô tả

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?

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.