Would Shiny be good for a non-GUI app?

shiny

#1

Lets say I want to periodically scrape a website, calculate some statistics, and write out a csv file to download. This doesnt really require a GUI element at all, it just needs to run periodically.

Is shiny the correct tool for this sort of application? or should I look to use something else?


#2

Hi @kieran, in short, a simple R script, coupled with a scheduler should work. If this is a Linux server, then you just need R, a cron job and the R script.

Going a bit beyond, instead of downloading the resulting CSVs, I would leave them in a folder inside the server that my shiny app can access, so I can see the trends and insights without moving files.


#3

For something non-critical, I would recommend a scheduler (as mentioned above:

Unix/Linux: cronR
Windows: taskscheduleR

For a critical job that others are relying on, you could consider a light-weight cloud solution. I’ve had success with something like Azure Functions - there’s a great how-to (involving continuous deployment on GitHub) here which I used to deploy (and basically forget about) a useless Twitterbot here!