R/abs_formatter.R

Defines functions abs_formatter

Documented in abs_formatter

#' Absolute value formatter for continuous_scale
#' 
#' This will print the absolute value for labeling on axis. Usefull for stacked
#' bar plots where negative values are not negative percentages but represent
#' negative groups.
#' 
#' @param x value to be reformatted.
#' @return the absolute value of x.
abs_formatter <- function(x) {
	return(abs(x))
}

Try the likert package in your browser

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

likert documentation built on May 30, 2017, 2:42 a.m.