I have a reactive object that i want to modify when the user click on the GO button. I tried this code and Per
gives a great result.
Now I want to do more than one modification considering the first one, so It seems like I should save RA_s
every time I modify it.
How can I handle with this problem ?
Code
shinyServer(function(input, output) {
RA_s <- reactive({
read.csv("C:/alay/Desktop/RA.csv")
})
Per <- reactive({
if(input$go == 0) return(RA_s())
else {
c = RA_s()
c[1] = rep(0,nrow(RA_s()))
}
c
})
})
sidebar <- dashboardSidebar(
sidebarMenu(
menuItem("Download", tabName = "d")
)
body<- dashboardBody(
tabItems(
tabItem(tabName = "d",
actionButton("go",'GO!') )
)
dashboardPage(
dashboardHeader(title = "Valo"),
sidebar,
body
)