ggplotly does not yet support stat_poly_eq from ggpmisc package
未关闭
还没有人认领这个 Issue。
- 主要语言
- R
- 星标
- 2.7k
- 派生
- 641
- PR 合并指标
- 30 天内没有已合并 PR
描述
Brief description of the problem
stat_poly_eq from ggpmisc package not currently supported with ggplotly for displaying equations of plotted models to a set of scatter data points.
my.formula <- y ~ x
ggplotly(ggplot(data = plotting_data1_1, aes(x = Days_observed, y = diff, group = year_month , colour = year_month)) + geom_point() + geom_smooth(data = plotting_data1_1, aes(group = year_month, colour = year_month), method = lm, se = FALSE, formula = my.formula) + stat_poly_eq(data = plotting_data1_1, aes(label = paste(..eq.label.., ..rr.label.., sep = "~~~"), colour = year_month),formula = my.formula, parse = TRUE)+ ylab("Actual estimate - Subsample estimate") + theme(plot.title = element_text(hjust = 0.5)))
#> Don't know how to automatically pick scale for object of type difftime. Defaulting to continuous.
Warning message:
In geom2trace.default(dots[[1L]][[1L]], dots[[2L]][[1L]], dots[[3L]][[1L]]) :
geom_GeomTextNpc() has yet to be implemented in plotly.
If you'd like to see this geom implemented,
Please open an issue with your example code at
https://github.com/ropensci/plotly/issues
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
首先运行提供的 ggplotly 示例,并检查关于尚未实现的 GeomTextNpc 几何对象的 geom2trace.default 警告。跟踪 ggplot 图层如何转换为 Plotly traces,然后验证 stat_poly_eq 是否在生成的图中渲染模型方程和 R² 标签。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- r
- 领域
- data-visualization
- Issue 类型
- 功能
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100