Reputation: 43
I had created one live Shiny dashboard. I know how to publish it in shinyapps.io.
Q1: I'm fetching data from json api and its changing frequently. Is it possible to set Auto-run of my app every hour automatically in shinyapps.io? If so how is it possible.
Q2: How to publish my shiny dashboard in AWS, including Auto Trigger too.
Thanks in Advance
Upvotes: 1
Views: 167
Reputation: 2261
Difficult to explain given the lack of reproducible example.
Use reactivePoll
instead of reactive
data <- reactivePoll(
intervalMillis = 1000 * 60 * 60,
session,
checkFunc = function(){
Sys.time()
},
valueFunc = function(){
# call API and return data here
}
)
The above will run checkFunc
at every intervalMillis
, if the results of checkFunc
is different then valueFunc
is returned.
This will work wherever you deploy, see Shiny Server Community edition to deploy your own server. You can see examples on digitalocean.
Upvotes: 1