animation in Microsoft word with Rmarkdown

Hi folks,

Does anyone know how to create animations using RMarkdown where the output is knitted to Microsoft Word?

I've seen an example here but it only works with HTML output: https://slides.yihui.org/2020-rstudio-conf-rmarkdown-recipes.html#13

Thanks,

Wayne

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.

The example you are sharing above is working fine in a Word output.

---
title: test
output: 
  word_document: default
---

```{r, animation.hook='gifski'}
library(gifski)
for (i in 1:2) {
  pie(c(i %% 2, 6), col = c('red', 'yellow'), labels = NA)
}
```

gifski is used to create a GIF by default here from several png files created in the chunk. Then the GIF file is embeded in the document which Word supports.

It is an R package with Shiny front end to analyse groundwater data and used by students, environmental engineers and regulators. It would be fantastic to be able to embed animations from the app into a word document.

What kind of animation do you look for from a shiny apps ? You can create any GIF or video from you shiny apps and include that in your output document.

Happy to help if I get more details on what you are looking for exactly. Thanks!

Thanks - this is exactly what I was looking for!

Great !

If your question's been answered (even by you!), would you mind choosing a solution? It helps other people see which questions still need help, or find solutions if they have similar problems. Here’s how to do it:

Done and thanks once again.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.