Commit e30e1438 authored by dmattek's avatar dmattek
Browse files

Bug fix:

Error shows up in app log when plotting.

"Warning: Error in <Anonymous>: cannot open file 'Rplots.pdf'"

Fix based on: https://github.com/ropensci/plotly/issues/494

Added in plotting f-n:
if (names(dev.cur()) != "null device") dev.off()
pdf(NULL)
parent 47483105
...@@ -239,6 +239,10 @@ shinyServer(function(input, output) { ...@@ -239,6 +239,10 @@ shinyServer(function(input, output) {
#ggplotly(p.out) #ggplotly(p.out)
cat(file=stderr(), 'trajPlot: out\n') cat(file=stderr(), 'trajPlot: out\n')
if (names(dev.cur()) != "null device") dev.off()
pdf(NULL)
return(ggplotly(p.out)) return(ggplotly(p.out))
}) })
......
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
# #
library(shiny) library(shiny)
library(shinyjs) #http://deanattali.com/shinyjs/
library(plotly) library(plotly)
shinyUI(fluidPage( shinyUI(fluidPage(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment