Jitter highlighted points deterministically
Usage
jitter_highlighted_points(
data,
jitter_width = 0.2,
jitter_height = 0.2,
seed = 11
)
Arguments
- data
A data frame containing `x`, `y`, and `border` columns.
- jitter_width
Width of the x jitter.
- jitter_height
Height of the y jitter.
- seed
Numeric value used to offset the deterministic sequence.
Value
A data frame with `x_plot` and `y_plot` columns.
Examples
df <- data.frame(
x = c(0, 1),
y = c(0, 1),
border = c(FALSE, TRUE)
)
jitter_highlighted_points(df, jitter_width = 0.2, jitter_height = 0.2)
#> x y border x_plot y_plot
#> 1 0 0 FALSE 0.000000 0.000000
#> 2 1 1 TRUE 1.091214 1.009685