#' Get File Path of User's Home Directory
#'
#' @param osType Optional. Type of operating system, one of \code{"unix"},
#' \code{"windows"}
#' @return path of user's home directory on windows (full path home directory
#' path but without '/Documents') or linux
#' @export
#'
get_homedir <- function(osType = .OStype())
{
home <- Sys.getenv("HOME")
if (osType == "windows") {
gsub("/Documents", "", home)
} else {
home
}
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.