labels in scale_color_manual() are ignored
未关闭
还没有人认领这个 Issue。
- 主要语言
- R
- 星标
- 2.7k
- 派生
- 641
- PR 合并指标
- 30 天内没有已合并 PR
描述
Reported first here: Scale_color_manual() labels not working
# insert reprex here
p <- ggplot(mtcars, aes(mpg, wt)) +
geom_point(aes(colour = factor(cyl)))
cols <- c("8" = "red", "4" = "blue", "6" = "darkgreen", "10" = "orange")
p <-
p + scale_colour_manual(
values = cols,
breaks = c("4", "6", "8"),
labels = c("four", "six", "eight")
)
The examples provided by plotly.com show the problem here: https://plotly.com/ggplot2/Scales/scale_manual/
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
在 R 中重现提供的 mtcars 示例,并将 scale_colour_manual() 的 breaks 和 labels 与链接的 Plotly 示例中显示的输出进行比较。没有指定文件或测试,因此请先定位 scale 转换或渲染的入口点;当 labels “four”、“six” 和 “eight” 正确出现在渲染后的 plot 中时,该 issue 即完成。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- r
- 领域
- data-visualization
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100