R/08_outputHelpers_logo.R

Defines functions psychonetrics_print_logo

# thanks to http://patorjk.com/software/taag-v1/!

 <- function(color = c("default","red","green","yellow","blue","magenta","cyan","white","silver")){
  # logo <- c("                        _                      _        _          ",
  #           "                      | |                    | |      (_)         ",
  #           "  _ __  ___ _   _  ___| |__   ___  _ __   ___| |_ _ __ _  ___ ___ ",
  #           " | '_ \\/ __| | | |/ __| '_ \\ / _ \\| '_ \\ / _ \\ __| '__| |/ __/ __|",
  #           " | |_) \\__ \\ |_| | (__| | | | (_) | | | |  __/ |_| |  | | (__\\__ \\",
  #           " | .__/|___/\\__, |\\___|_| |_|\\___/|_| |_|\\___|\\__|_|  |_|\\___|___/",
  #           " | |         __/ |                                                ",
  #           " |_|        |___/                                                 ","\n"
  # )
  color <- match.arg(color)
  logo <- c("                        _                      _        _          ",
            "                      | |                    | |      (_)         ",
            "  _ __  ___ _   _  ___| |__   ___  _ __   ___| |_ _ __ _  ___ ___ ",
            " |  _ \\/ __| | | |/ __|  _ \\ / _ \\|  _ \\ / _ \\ __|  __| |/ __/ __|",
            " | |_) \\__ \\ |_| | (__| | | | (_) | | | |  __/ |_| |  | | (__\\__ \\",
            " | .__/|___/\\__, |\\___|_| |_|\\___/|_| |_|\\___|\\__|_|  |_|\\___|___/",
            " | |         __/ |                                                ",
            " |_|        |___/                                                 ","\n"
  )
if (color == "default"){
  cat(paste0(logo,collaps="\n"))
} else {
  cat(do.call(color,list(paste0(logo,collaps="\n"))))
}
  
}

Try the psychonetrics package in your browser

Any scripts or data that you put into this service are public.

psychonetrics documentation built on Oct. 3, 2023, 5:09 p.m.