prettylog function

Pretty Breakpoints on Log Scale

Pretty Breakpoints on Log Scale

Compute a sequence of "round" values which cover the range of x on the log scale.

prettylog(x, lead = c(1, 5), extra = 5)

Arguments

  • x: A numeric vector.
  • lead: An integer vector giving the desired lead digits of pretty values on the log scale, default c(1, 5).
  • extra: An integer scalar giving the desired number of additional non-log scale values to include, default 5.

Returns

A numeric vector of pretty values covering the range of x on the log scale.

Examples

vals <- rlnorm(100, 6) summary(vals) prettylog(vals, 1, 0) prettylog(vals, 1) prettylog(vals, c(1, 2, 5))
  • Maintainer: Jean V. Adams
  • License: GPL
  • Last published: 2017-03-20