#' Title
#'
#' set.dir set the working directory. If the provided working directory does not exist,
#' the function create a new folder.
#'
#' @param dir is a string with the directory name.
#'
#' @return
#' @export
#'
#' @examples
#' #For mac
#' set.dir("/Users/user/Documents/example)
set.dir <- function(dir) {
dir.create(dir, showWarnings = FALSE)
setwd(dir)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.