Is it impossible to have one slide in an R presentation, say ioslides, that is an interactive dashboard? In Rstudio, flexdashboard must open as a different file and Shiny dashboard doesn't run in a slide presentation. Thanks
You can use runtime: shiny in the header of your document.
---
output: ioslides_presentation
runtime: shiny
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = FALSE)
```
## Slide {.smaller}
### Here are two Shiny widgets
```{r echo = FALSE}
selectInput("n_breaks", label = "Number of bins:",
choices = c(10, 20, 35, 50), selected = 20)
```
### ...that build a histogram.
```{r echo = FALSE}
renderPlot({
hist(faithful$eruptions, probability = TRUE,
breaks = as.numeric(input$n_breaks),
xlab = "Duration (minutes)",
main = "Geyser eruption duration")
})
```
The result is a slide with an an interactive selectInput that allows to change the breaks of the histogram:

You can find more details here: https://shiny.rstudio.com/articles/interactive-docs.html
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With