nice_inline_r: Allows user to write examples of inline R code.

View source: R/nice_things.R

nice_inline_rR Documentation

Allows user to write examples of inline R code.

Description

Yihui gets the credit for this one. http://stackoverflow.com/questions/20409172/how-to-display-verbatim-inline-r-code-with-backticks-using-rmarkdown Writing text to give examples of inline r code is tricky. This function should achieve that.

Usage

nice_inline_r(x)

Arguments

x

A string of R code for printing as code, inline

Value

A formatted string

Examples

nice_inline_r("round(3.77155454, 3)")

simonthelwall/nicethings documentation built on Feb. 27, 2023, 3:15 p.m.