Drop support for orphaned plotly package
Change-Id: I59e5339c613fc1eef89bb81afc0c260e2f60ed16
diff --git a/demo/regional.R b/demo/regional.R
index 05a3b6d..9480d67 100755
--- a/demo/regional.R
+++ b/demo/regional.R
@@ -3,7 +3,6 @@
library(ggplot2)
library(raster)
library(broom)
-library(plotly)
library(htmlwidgets)
devAskNewPage(ask = FALSE)
@@ -58,14 +57,8 @@
}
}
plot <- updatePlot(query, map, regions)
- pp <- ggplotly(plot)
- for (i in 1:nrow(regions)) {
- j <- grep(paste0(regions$region[i], "\""), pp$x$data, perl=TRUE)
- pp$x$data[[j]]$customdata <- regions[i,]$url
- }
- ppp <- onRender(pp, "function(el, x) { el.on('plotly_click', function(d) { var url=d.points[0].data.customdata; window.open(url, 'korap') })}")
- print(ppp)
- pp
+ print(plot)
+ plot
}
updatePlot <- function(query, map, regions) {