> # explicit package > cat(highlight("MASS::addterm()")) MASS::addterm() > cat(highlight("MASS::addterm")) MASS::addterm > cat(highlight("?MASS::addterm")) ?MASS::addterm > # implicit package > cat(highlight("library(MASS)")) library(MASS) > cat(highlight("addterm()")) addterm() > cat(highlight("median()")) median() > # local package > cat(highlight("test::foo()")) test::foo() > # operators / special syntax > cat(highlight("1 + 2 * 3")) 1 + 2 * 3 > cat(highlight("x %in% y")) x %in% y > cat(highlight("if (FALSE) 1")) if (FALSE) 1 > cat(highlight("f <- function(x = 'a') {}")) f <- function(x = 'a') {} > # ansi escapes + unicode > cat(highlight("# \033[34mblue\033[39m")) # blue