问题
I'm entering the task of creating automated reports using R.
I have all the data that I need in a dataframe, and I have a template of the report in pptx format. The PPT has quite some design, so I'm preparing the slides instead of working with a layout pattern to make it easier. Slides have some pre-written paragraphs, and I need to insert data into specific positions of those paragraphs: for example, in one text box it says "in this case, there is a "value1"% of ..." and I would need to replace the "value1" tag with its correct value from my dataframe. I also need to insert graphs.
So, I've been trying out the Office package. I see that it lets me open an existing .pptx file, read it's contents and add new slides or objects into existing slides, but is there a way to edit an existing paragraph and replace a word such as "value1" with the specific value I need?
Thanks a lot!
来源:https://stackoverflow.com/questions/60624415/is-there-a-way-to-edit-existing-paragraphs-in-slides-using-officer-or-any-other