log_CT_plus: Log transform a vector (skew corrected)
Description
Performs a log transform on a numeric vector, but with consideration for the direction of the skew. The aim
here is to reduce the absolute value of skew, regardless of its direction.
Usage
log_CT_plus(x, na.rm = FALSE)
Value
A log-transformed vector of data, and treatment details wrapped in a list.
Arguments
x
A numeric vector
na.rm
Set TRUE to remove NA values, otherwise returns NA.
Details
Specifically:
If the skew of x is positive, this performs a modified "COIN Tool log" transform: log(x-min(x) + a), where
a <- 0.01*(max(x)-min(x)).
If the skew of x is negative, it performs an equivalent transformation -log(xmax + a - x).