## ---- eval=FALSE--------------------------------------------------------------
# tools::R_user_dir("grapho", "config")
## ---- eval = FALSE------------------------------------------------------------
# .GlobalEnv$.grapho
## ---- include=FALSE-----------------------------------------------------------
require(digest)
## -----------------------------------------------------------------------------
substr(digest::digest(
c(Sys.getenv("HOME"),
Sys.getenv("LANG"),
Sys.getenv("R_PLATFORM")),
algo = "sha512"
), 1, 40)
## -----------------------------------------------------------------------------
substr(digest::digest(
date(), algo = "sha512"
), 1, 40)
## ---- include=FALSE-----------------------------------------------------------
require(grapho)
## -----------------------------------------------------------------------------
.grapho
## -----------------------------------------------------------------------------
show_config()
## -----------------------------------------------------------------------------
show_config()
## -----------------------------------------------------------------------------
create_filename <- function(filetype) {
paste0(
format(Sys.time(), "%y%d%mT%H%M%S"), "-",
filetype, "-",
.GlobalEnv$.grapho$ids$user_id, "-",
.GlobalEnv$.grapho$ids$session_id
)
}
create_filename("current_plot")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.