You can clone with
HTTPS or Subversion.
Currently, knitr converts
`r 2 + 2`
and the Markdown converter then generates
However, I think it would be better default behaviour to just print the result, WITHOUT enclosing the result in backticks (which are in turn converted to code tags).
r 2 + 2
Alternative, is there a way of using handles or some other feature to disable the use of <code> tags for inline code in R Markdown?
I don't think knitr is adding this markup. I believe it must be markdown, which is translating inline to code. AFAIK, markdown was not designed for reproducible document writing. So the inline usage was mainly to highlight code, which is why you are seeing the markup.
@ramnathv I updated the issue to clarify my understanding of the role of knitr and the markdown to html program. I'm essentially asking whether the default behaviour in knitr for inline commands should be to just print the result rather than surrounding the result in backticks. I think this would be more flexible.
Also, I imagine you have not seen what R Markdown can do. It supports inline commands now. See the answer to this question.
sorry, this is not well documented; the solution is to use I(), which means not to wrap my result in any tags; just leave it as-is, e.g. I(2+2)
it is hidden deep in https://github.com/yihui/knitr/blob/master/R/hooks-md.R#L38
Thanks @yihui . That works perfectly. I added the details to this question on stack overflow.