Bullet Charts: Indicator Delta Reference shows dash symbol when value and reference are equal
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- R
- Star
- 2.7k
- Fork
- 641
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
I am creating bullet charts using the guidance found here: https://plot.ly/r/bullet-charts/
All is working as expected, however when the value and reference values are the same, the rendered plot shows no difference. Just a straight line. I should say 0 as there's a difference of zero.
Example below with straight line for difference rendered.
plot_ly(
type = "indicator",
mode = "number+gauge+delta",
gauge = list(shape = "bullet"),
delta = list(reference = .333, valueformat='%', relative=FALSE,position='right'),
value = .33,
domain = list(x = c(0, 1), y = c(0, 1)),
title= list(text = "Profit"),
height = 150)
However, if I add an additional digit to the reference or value as shown below, a percent difference of -0 or +0 is shown.
plot_ly(
type = "indicator",
mode = "number+gauge+delta",
gauge = list(shape = "bullet"),
delta = list(reference = .333, valueformat='%', relative=FALSE,position='right'),
value = .33,
domain = list(x = c(0, 1), y = c(0, 1)),
title= list(text = "Profit"),
height = 150)
plot_ly(
type = "indicator",
mode = "number+gauge+delta",
gauge = list(shape = "bullet"),
delta = list(reference = .33, valueformat='%', relative=FALSE,position='right'),
value = .333,
domain = list(x = c(0, 1), y = c(0, 1)),
title= list(text = "Profit"),
height = 150)
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu bằng cách tái hiện ví dụ bullet-chart trong R và lần theo đường dẫn kết xuất delta của chỉ báo trong plotly.R. issue không nêu tên tệp nguồn hoặc kiểm thử nào; hãy xác định phạm vi bao phủ liên quan và thêm một kiểm tra hồi quy cho thấy delta bằng 0 khi giá trị và giá trị tham chiếu bằng nhau.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- r
- Lĩnh vực
- data-visualization
- Loại issue
- Lỗi
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 45/100