read_docx
From officer v0.3.4
by David Gohel
open a connection to a 'Word' file
read and import a docx file as an R object representing the document.
Usage
read_docx(path = NULL)# S3 method for rdocx
print(x, target = NULL, ...)
# S3 method for rdocx
length(x)
Arguments
- path
path to the docx file to use as base document.
- x
an rdocx object
- target
path to the docx file to write
- ...
unused
Examples
# NOT RUN {
# create an rdocx object with default template ---
read_docx()
print(read_docx())
# write a rdocx object in a docx file ----
if( require(magrittr) ){
read_docx() %>% print(target = tempfile(fileext = ".docx"))
}
# how many elements are there in the document ----
length( read_docx() )
# }
Community examples
Looks like there are no examples yet.