You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A common use of the caption grob produced by finalize_plot is to provide both a "note" and a "source" that should be a bit separate from each other. Most examples in the cookbook, for example, include <br><br> between text to create the necessary visual spacing.
A logical and easy add would be to allow the caption argument to take a vector of text entries, which finalize_plot would then combine with the necessary line breaks in the backend.
The text was updated successfully, but these errors were encountered:
As long as it remains backwards-compatible (i.e. a single string can still be supplied to the parameter, not wrapped in a c()) I have no problem with this. I guess it would just be a matter of checking whether the supplied value is a vector and, if so, returning cat(the_vector, sep = "<br><br>")?
> caption <- c("This is a note.", "This is a source.")
> paste(caption, collapse = "<br><br>")
[1] "This is a note.<br><br>This is a source."
> caption <- "This is a note."
> paste(caption, collapse = "<br><br>")
[1] "This is a note."
A common use of the caption grob produced by
finalize_plot
is to provide both a "note" and a "source" that should be a bit separate from each other. Most examples in the cookbook, for example, include<br><br>
between text to create the necessary visual spacing.A logical and easy add would be to allow the
caption
argument to take a vector of text entries, which finalize_plot would then combine with the necessary line breaks in the backend.The text was updated successfully, but these errors were encountered: