Learn R Programming

mindr (version 1.2.1)

md2mm: Convert markdown or rmarkdown files to mindmap files.

Description

Convert markdown or rmarkdown files to mindmap files.

Usage

md2mm(pattern = "*.[R]*md$", title = NA, path = ".", remove_curly_bracket = FALSE, 
    savefile = TRUE, savefilename = NA, backup = TRUE, bookdown_style = TRUE, 
    keep_eq = FALSE, method = c("regexpr", "pandoc"))

Arguments

pattern

an optional regular expression for filtering the input files. See help(dir).

title

character. The title of the output file.

path

character. The path of the folder which contains the input file(s).

remove_curly_bracket

logical. Whether to remove #ID in the headers of the markdown file (usually in a 'bookdown' https://github.com/rstudio/bookdown project).

savefile

logical. Whether to save the output as a file.

savefilename

character. Valid when savefile == TRUE.

backup

logical. Whether the existing target file, if any, should be saved as backup.

bookdown_style

logical. whether the markdown files are in bookdown style, i.e. index.Rmd at the beginning, # (PART), # (APPENDIX) and # References as an upper level of normal # title

keep_eq

logical. whether to keep LaTeX equations.

method

"regexpr" uses regular expressions, 'pandoc' uses pandoc to find the headings.

Value

a mindmap file, which can be viewed by common mindmap software, such as 'FreeMind' (http://freemind.sourceforge.net/wiki/index.php/Main_Page) and 'XMind' (http://www.xmind.net).

Examples

Run this code
# NOT RUN {
path <- system.file("examples/md", package = "mindr")
md2mm(path = path)
md2mm(path = path, remove_curly_bracket = TRUE)
# }

Run the code above in your browser using DataLab