9

I am not sure if I can show any reproducible example here, however let me narrate the issue I am facing with my Shiny app.

I have a Shiny app, which is basically data driven. All my required data is saved in an RData file which is placed in WWW folder. When user put my Shiny app's address (which is hosted on Amazon AWS) i.e. when my Shiny app starts, that RData file is loaded onto R, and then subsequent calculation starts.

The issue is that, my RData file is of quite huge size ~50MB. So R takes quite long time to load that onto memory. From User's perspective, he/she is not sure what is happening behind the screen, that makes some of them leave my App.

So I was thinking if I can put some progress bar to show User something is happening, as that Progress bar would be displayed only during the time when R is loading my RData file. I am aware of various Progress bar schemes available for Shiny, however as far as I know they are to display progress only during calculation (e.g. simulation) not during loading something.

Any idea if it is possible to put some Progress bar during loading RData, package etc?

Thanks for any pointer.

3
  • Have a look at stackoverflow.com/questions/31397741/… Commented Apr 4, 2018 at 15:45
  • Hi DJack - the link is helpful. However, it implements server-side loading of data. Server-side loading of Packages also can be done with this approach. But how can a similar thing be done for UI side loading of package/data? Sometimes loading of package takes considerable amount of time Commented Apr 4, 2018 at 19:00
  • I am looking for an answer to this same question, except I am using fread (which has a built-in loading bar that prints to the console). Any news on a solution to this yet? Commented Nov 14, 2018 at 17:14

1 Answer 1

2

maybe a bit late but I share what I used, should it be useful for someone else.

Take a look at the shinycssloaders package (https://github.com/andrewsali/shinycssloaders).

By adding a simple function withSpinner and set a few parameters, you'll be able to set loader animations to Shiny apps. Furthermore you can select different spinners by looking at this link https://projects.lukehaas.me/css-loaders/.

I used it when I made this app: https://abenedetti.shinyapps.io/bioNPS/ Look at the Species Choropleth map section.

Edit: Maybe this article and this app could help. Did you had a look at them?

Sign up to request clarification or add additional context in comments.

1 Comment

Thanks for sharing this information. While this is useful to display that App is still working on, however I wanted to have something to display how much work is still remaining (like %) - this information will not be available with this.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.