Replies: 1 comment
-
|
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I'm trying to use expression in guide primitive. I can see from key_range help page that name could be set as a list of expression but in unable to make it work.
Am I missing something ?
Here is an exemple based on guide composition help page :
`
standard <- ggplot(mpg, aes(displ, hwy)) +
geom_point() +
labs(
x = "Engine displacement (litres)",
y = "Highway Miles per Gallon"
) +
theme(axis.line = element_line())
range_key <- key_range_manual(
start = c(2, 4), end = c(5, 6),
name = list(2,expression("Second^{2}"))
)
standard + guides(x = compose_stack(
"axis_base",
primitive_bracket(range_key, "curvy")
))
`
Thanks a lot
Beta Was this translation helpful? Give feedback.
All reactions