Replace superseded coord_flip() with swapped aesthetics in ppc_error_scatter_avg
Nobody has claimed this yet.
- Dominant language
- R
- Stars
- 442
- Forks
- 93
- Avg merge
- 3h 11m
- Merged PRs (30d)
- 1
Description
ppc_error_scatter_avg() and the deprecated ppc_error_scatter_avg_vs_x() in R/ppc-errors.R use coord_flip(), which is marked as [Superseded] in ggplot2.
From the ggplot2 docs:
This function is superseded because in many cases,
coord_flip()can easily be replaced by swapping the x and y aesthetics, or optionally setting theorientationargument in geom and stat layers.
https://ggplot2.tidyverse.org/reference/coord_flip.html
Two call sites at lines 260 and 330 of R/ppc-errors.R.
Would it be welcome to replace these with swapped aesthetics? Happy to open a PR if so.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in R/ppc-errors.R at the two coord_flip() call sites around lines 260 and 330, within ppc_error_scatter_avg() and the deprecated ppc_error_scatter_avg_vs_x(). Review the existing aesthetics and ggplot2 guidance on replacing coord_flip() with swapped aesthetics. Done means both call sites no longer use the superseded function while preserving the plots' intended orientation; run the package tests or relevant plotting checks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- r
- Domain
- data-visualization
- Issue type
- Refactor
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 68/100