Via RStudio API, it is possible to run programmatically some RStudio IDE commands from this list that work in Visual Markdown Editor (VME) too, e.g.,
rstudioapi::executeCommand("insertChunk")
Unfortunately, not all VME-related commands are present in the list. So how can one programmatically run Visual Markdown Editor-specific commands, e.g., insert part heading (H1), insert inline math ($a + b$
), etc., in RStudio?