Skip to content Skip to sidebar Skip to footer

R Script Do Not Write In Sqlite Db If I Run The Script In Shiny

I have a function that do some calculation and write the result in a sqlite db. With a shiny application I see the result but if I look into the db I can not see it. Any suggestion

Solution 1:

The contents of reactiveneed to have a reactive input to initiate the function. Maybe something like:

shinyServer(function(input, output){
    myReactives <- reactiveValues(myDF = my_function())
    X = reactive({ myReactives$myDF })
})

x() Should now contain the data.

Post a Comment for "R Script Do Not Write In Sqlite Db If I Run The Script In Shiny"