By default, word document is not creating any folder. Here is a small example of the default behavior
# dummy work dir for the example
dir.create(temp_dir <- tempfile())
old <- setwd(temp_dir)
# we create a Rmd with docx output
xfun::write_utf8(c(
"---",
"title: a docx",
"output: rmarkdown::word_document",
"---",
"",
"# A title",
"Some content with a plot",
"",
"```{r}",
"plot(iris)",
"```",
""
), "test.Rmd"
)
# only the Rmd doc
list.files(all.files = TRUE)
#> [1] "." ".." "test.Rmd"
# we render
rmarkdown::render("test.Rmd", quiet = T)
# only the docx document in addition
list.files(all.files = TRUE)
#> [1] "." ".." "test.docx" "test.Rmd"
setwd(old)
unlink(temp_dir)
Created on 2020-02-12 by the reprex package (v0.3.0.9001)
You see there is only the docx file created in the folder where the Rmd is. We need more information to understand what happens. Can you provide a Rmd example with this behavior ?
With Rmarkdown issue, it is very important to know what is inside your document. Also, with all type of issue, it helps us a lot if we can reproduce on our hand. Currently, we can't.
Some question to help:
- Which version of Rmarkdown are you using ?
packageVersion("rmarkdown")
- Which version of pandoc ?
rmarkdown::pandoc_version()
Thank you