#' Check if code is running on Hábrók HPCC
#'
#' @return Boolean. `TRUE` if called from Hábrók HPCC, FALSE if not.
#' @export
#'
#' @examples
#' on_cluster <- is_on_cluster()
#'
#' @author Pedro Santos Neves
is_on_cluster <- function() {
if (identical(Sys.getenv("SLURM_CLUSTER_NAME"), "habrok")) {
return(TRUE)
} else {
return(FALSE)
}
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.