Converts a document originally created with redoc()
back to R
Markdown, including changes made to text in MS Word.
dedoc(docx, to = NULL, dir = ".", track_changes = "comments_only", block_missing = "comment", inline_missing = "omit", wrap = getOption("redoc.wrap", 80), overwrite = FALSE, orig_docx = NULL, orig_codefile = NULL, verbose = FALSE)
docx | The `.docx`` file to convert |
---|---|
to | the filename to write the resulting |
dir | The directory to write the `.Rmd`` to. Defaults to current working directory |
track_changes | How to deal with tracked changes and comments in the
|
block_missing, inline_missing | What to do about code blocks or inline code whose output has been removed in the editing of the Word document. "restore" attempts to restore the code as close to its original location in the document as possible. "comment" will do so but wrap it in HTML comments. "omit" will not restore the code at all. |
wrap | The width at which to wrap text. If |
overwrite | Whether to overwrite an existing file |
orig_codefile, orig_docx | The original |
verbose | whether to print pandoc progress text |
R chunks may be lost in the editing process if using non-Microsoft word processors (e.g. LibreOffice or in copy-and-pasting text into a new document.