Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User question about dynamic names #896

Open
IndrajeetPatil opened this issue Nov 5, 2023 · 0 comments
Open

User question about dynamic names #896

IndrajeetPatil opened this issue Nov 5, 2023 · 0 comments

Comments

@IndrajeetPatil
Copy link
Owner

IndrajeetPatil commented Nov 5, 2023

I'm trying to do something like the following, which I feel like I'm close to getting but am still failing.

If in your example:

grouped_ggbetweenstats(
  data = filter(ggplot2::mpg, drv != "4"),
  x = year,
  y = hwy,
  grouping.var = drv
)

You wanted to customise each title to be something like

"In this plot `f/r` is the drv type". 

How would I achieve that? I've tried things like:

ggplot.component = labs(title = paste0("In this plot  ",  title, "is the drv type"))
ggplot.component = labs(title = paste0("In this plot  ",  names(.), "is the drv type"))

and a lot of other variants.

Thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant