Does anyone know a trick for doing something like this in RMarkdown:
![alt text](`r my_fun(x)`)
It's the closing bracket of the function call that causes the problem. It thinks it is the end of the image location bracket.
I know a few ways round. Of course I can pre-assign the function output to an object and then just inline r my_obj
within the markdown. But that is extra code. I'm trying to keep things tight if possible.
I can just do it in HTML with <img />
. But the markdown shorthand is much nicer and more succinct.
I could use knitr::include_graphics()
, but that doesn't seem to allow for alt text.
No big deal if not possible, I thought I would just see if anyone knows a neat way to do this.