How to include DiagrammeR/mermaid flowchart in a Rmarkdown file
问题 I have an R markdown file: --- title: "Untitled" author: "Me" output: html_document --- ```{r setup, include=FALSE} knitr::opts_chunk$set(echo = TRUE) ``` ## R Markdown This is an R Markdown document. As well as a DiagrammeR/mermaid chart: graph LR A-->B How can I add the chart in the R-markdown? 回答1: Actually it is trivial: title: "Untitled" author: "Me" output: html_document --- ```{r setup, include=FALSE} knitr::opts_chunk$set(echo = TRUE) ``` ## R Markdown This is an R Markdown document.