2

I have a Shiny app that pulls data from SQL upon opening the app. The data set has a large number of observations and is added to daily. Currently it takes about 16 seconds to load the data. I'd like to add a progress bar to show users that the app is in fact running. I have looked up progress bars such as that here. However, everything I have found is within the server function. Currently, I am pulling the data only once outside of the function, then subsetting it (based on user inputs) within the function. Is there a way to do create a progress bar for this?

My other thought was to create something that appears when the app loads and disappears once the data has been fully retrieved but I do not know where to start for that.

Lost
  • 331
  • 1
  • 12
  • 1
    Progress bar wouldn't be that useful as you really dont know how long the data will take to query, it might take a few mins for example so displaying percentage complete is cumbersome. May I suggest you look into `shinycssloaders` package which has a lot of waiting spinners you can add to your project https://github.com/andrewsali/shinycssloaders – Pork Chop Jul 12 '18 at 16:12
  • @PorkChop I will give it a try, but I am uncertain as to where in my code I would put this – Lost Jul 13 '18 at 11:52
  • in the ui, straight after the widget – Pork Chop Jul 13 '18 at 12:03

0 Answers0