All, I am trying to write a data frame into RDS file in Shiny app. I am using below code.
AgName <- gsub("\\s","",paste(mtrl1,'_',stage1,'_',sample1,'.RDS', collapse = ' '))
saveRDS(Input_Data2, AgName )
But it is throwing following error message:
Error: cannot open the connection
Same code is running fine on R command line but not in Shiny app. Any help will be highly appreciated. Thanks!
Thanks Flick!
I used below code as well, but no luck.
setwd("/opt/shiny-server/samples/sample-apps/P-AG-Disc4/")
AgName <- gsub("\\s","",paste(mtrl1,'_',stage1,'_',sample1,'.csv', collapse = ' '))
saveRDS(Input_Data2, file=AgName )
Thanks Flick!
You were right. Directory was not having write permission on the directy, where I was trying to write. Thanks again soo much!