The following code should do (suppose the event has passed only 4 minutes):
EventTime <- Sys.time() + 4*60 output$eventTimeRemaining <- renderText({ invalidateLater(1000, session) paste("The time remaining for the Event:", round(difftime(EventTime, Sys.time(), units='secs')), 'secs') })
with the following output:
The time remaining for the Event: 226 secs
source share