Support `linewidth` aesthetic to control the sizing of the width of lines
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 45/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 停滞
- 技术栈
- python
调研方向
Issue 提到了 geom_density 示例,但没有指定源文件或测试路径。首先跟踪 plotnine 如何处理 line geoms 现有的 size aesthetic,然后将所请求的 linewidth 行为与链接的 ggplot2 指南进行比较。当提供的示例接受 linewidth=0.75 并使用它控制密度线宽度时,即表示完成。
由索引模型根据 Issue 内容生成。
描述
ggplot2 recommends using the linewidth aesthetic instead of size as of version 3.4.0 (see this blog post here: https://www.tidyverse.org/blog/2022/11/ggplot2-3-4-0/). The argument in the blog post is as follows: "The reason for this change is that prior to this release size was used for two related, but different, properties: the size of points (and glyphs) and the width of lines. Since one is area based and one is length based they fundamentally needs different scaling and the default size scale has always catered to area sizing, using a square root transform. "
Ideally, the following works in plotnine as well (as it does in ggplot2):
from plotnine import *
from palmerpenguins import load_penguins
penguins = load_penguins().dropna()
(ggplot(penguins, aes(x = "body_mass_g", color = "species"))
+ geom_density(linewidth = 0.75)
)
- 主要语言
- Python
- 星标
- 4.8k
- 派生
- 269
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
has2k1/plotnine 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 78/100
-
Feature request: add rotation_mode param to geom_text可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭Feature
难度 2/5 1-3 小时 新手友好度 66/100
-
position_dodge2() leaves nested rectangles overlapping可能已有人在做 @MahnoorAhmed999 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 35/100
-
Enhancement
难度 3/5 半天 新手友好度 55/100
-
Enhancement
难度 4/5 3-5 天 新手友好度 52/100
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 68/100
bad-antics/lateralus-lang#1623 ·
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 74/100
fossguild/thelifesnake#82 ·
维护者通常 1 天内回复
-
Unfitted DialectClassifier crashes with a confusing ValueError: raise a clear "not fitted" error未关闭good first issue
难度 2/5 1-3 小时 新手友好度 88/100
omarelshamy25x/shamy-arabic-nlp#111 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
pietbarber/Manage2Soar#1189 ·
维护者通常 1 天内回复
-
BUG: write_netcdf fails on Tutorial 3 BEM output with pandas CategoricalDtype DOF coordinates可能已有人在做 @dtgaebe 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 72/100
sandialabs/WecOptTool#467 ·