Skip to content

Commit

Permalink
download: save version info (R, ggplot, plotly)
Browse files Browse the repository at this point in the history
  • Loading branch information
HendrikSchultheis committed Jun 7, 2018
1 parent 928e966 commit 884042c
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion R/function.R
Original file line number Diff line number Diff line change
Expand Up @@ -1198,8 +1198,11 @@ download <- function(file, filename, plot, width, height, ppi = 72, save_plot =
if (save_plot) {
# create temp file name
plot_object_file <- tempfile(pattern = "plot_object", fileext = ".RData")
ggplot2_version <- as.character(packageVersion("ggplot2"))
plotly_version <- as.character(packageVersion("plotly"))
r_version <- R.Version()$version.string

save(plot, file = plot_object_file)
save(plot, ggplot2_version, plotly_version, r_version, file = plot_object_file)

files <- c(files, plot_object_file)
}
Expand Down

0 comments on commit 884042c

Please sign in to comment.