Replies: 1 comment 4 replies
-
I let @jjallaire answer as he is the one with the best knowledge on the visual editor. |
Beta Was this translation helpful? Give feedback.
4 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.
Uh oh!
There was an error while loading. Please reload this page.
-
Description
I am trying to display a callout box that contains an R Code chunk with a caption that is dynamically set by the value of an R variable in my environment. I am able to achieve this without any problem using the source editor in R Studio with the following code:
This results in the following (and is exactly what I am trying to achieve):
Now, I am wondering if I can achieve the same result using the visual editor or IDE in R studio. When I switch back to the visual editor and click on the and click the three dots (...) on the .callout-note it displays the following:
If I modify the caption text box to be r mycaption2 and then switch back to the visual editor I see the code has been modified as follows:
As you can see the backticks have been removed from the callout-not caption (## r mycaption2). Is there a way to enter a r variable name into the visual editor caption so that backticks will appear in the visual editor as (## `r mycaption2`) so that the value of the value of the r variable will appear in my callout box caption, resulting in the same output as shown in my first output screenshot above?
Beta Was this translation helpful? Give feedback.
All reactions