Plot 'slideshow' during execution in Shiny

I'm building a Shiny app that, after responding to user input, creates several plots. The catch is that I want the the plots to display: (1) all in the same renderPlot UI pane; (2) for 6-8 seconds each; and (3) while the code continues to run in the background (creating the subsequent plots). So if there are 4 plots to display, the user might be looking at plot number 3 while plot number 4 is being created (and so on and so forth). The effect I'm going for is kind of like a timed slide show.

Is there a package or framework for this sort of thing? If not, how would I achieve this effect? Any guidance would be greatly appreciated.

Shiny default is to be single threaded, therefore This would require async programming. I'd consider ipc package for such. However as a user I think I would be very frustrated with an auto slide show of plots, I'd want stability (that a plot wouldn't disappear while I was reading it) and if the plots are related I may want to compare them, I.e. see more than one at a time.

1 Like

Thanks Matthias, I think this is a much more manageable solution. I'll try it out!

The slickR package may help.
In addition to the comment before I am not sure if you are able to update the plotlist, when it was started.
But when you already know the names of the files you may generate the list in advance, there is also a "lazy loading" which only loads the image when it's actually shown...

1 Like

Interesting, thanks for sharing!