knitr::opts_chunk$set( comment = "#>", tidy = FALSE, error = FALSE)
Unicode symbols with Windows fallbacks
Inspired by (and mostly copied from) the figures JavaScript project.
Stable version:
install.packages("clisymbols")
Development version:
pak::pak("r-lib/clisymbols")
library(clisymbols) cat(symbol$tick, "All good\n") cat(symbol$cross, "Problem\n")
Here is a list of all symbols, with their names:
for (i in seq_along(symbol)) { cat(symbol[[i]], "\t", names(symbol)[i], "\n", sep = "") }
Some terminals do not support (all) Unicode characters, and on these reasonable ASCII substitutes are used:
for (i in seq_along(clisymbols:::symbol_win)) { cat(format(clisymbols:::symbol_win[[i]], width = 4), names(clisymbols:::symbol_win)[i], "\n", sep = "") }
MIT © Gabor Csardi and Sindre Sorhus
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.