The alpha aes in geom_line is not reflecting back in legend symbol

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

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
57/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
kotlin, python
Lĩnh vực
data-visualization

Hướng nghiên cứu

The report reproduces the legend alpha mismatch for geom_line, geom_path, and geom_lollipop in lets-plot 4.11.0, while geom_point and bar geoms work. Start by tracing how line and lollipop legend symbols are rendered and compare their alpha handling with the working point legend. Done when the legend symbols reflect the mapped alpha consistently with the plotted geoms; the issue names no source files or tests.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

I am using python lets-plot on version 4.11.0.

When using an alpha aes on a line geom (i only tested line, path, lollipop), the alpha is not reflecting back in the legend symbols. So they are all alpha=1. For the lollipop, the circle does show the alpha, while the line doesn't.

Using geom_point, _bar..., the alpha does work fine in the legend.

n = 100
x = np.linspace(-4 * np.pi, 4 * np.pi, n)
y = np.sin(x)
c = np.repeat(['a', 'b'], n//2)

gggrid(
    [
        ggplot({'x': x, 'y': y, 'c':c}, aes(x='x', y='y', alpha='c')) + geom_line(),
        ggplot({'x': x, 'y': y, 'c':c}, aes(x='x', y='y', alpha='c')) + geom_lollipop(),
        ggplot({'x': x, 'y': y, 'c':c}, aes(x='x', y='y', alpha='c')) + geom_point(),
    ]
)
Image
Ngôn ngữ chính
Kotlin
Star
1.8k
Fork
63
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

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.

Issue khác của JetBrains/lets-plot

Tất cả issue của JetBrains/lets-plot

Issue tương tự

Thêm issue về Kotlin

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.