If I plot a gganimate object in a Shiny app, it takes up the whole screen! Completely removing all my nice input bars. I want to know, how do I keep my inputs?
Please take a look at this simple example.
Thanks in advance for the help !
Dan
library ( shiny )
library ( gganimate)
library ( ggplot2)
ui = fluidPage(
textInput("a","put letters here",value = "dave" ),
plotOutput("b")
)
server = function(input, output){
output$b= renderPlot ( {
p = ggplot(iris, aes(x = Petal.Width, y = Petal.Length)) +
geom_point()+
transition_states(Species)+
ggtitle ( input$a)
animate ( p,nframes = 40)
} )
}
shinyApp ( ui , server)