logHist {berryFunctions}R Documentation

Histogram of logarithmic values

Description

Draw histogram of values on a logarithmic scale with nice axis labels

Usage

logHist(
  x,
  logargs = NULL,
  main = xmain,
  xlab = xname,
  col = "tan",
  add = FALSE,
  las = 1,
  ylim = NULL,
  freq = TRUE,
  quiet = FALSE,
  ...
)

Arguments

x

Vector of numerical values

logargs

A list of arguments passed to logAxis. DEFAULT: NULL

main

Title of graph, internally from x. DEFAULT: internal name representation

xlab

X axis label. DEFAULT: internal: name of x

col

Color of histogram bars

add

Logical: add to existing plot?

las

Integer: label axis style. DEFAULT: 1 (numbers upright)

ylim

2 Numbers: y-axis range. DEFAULT: NULL

freq

Logical: counts instead of density? DEFAULT: TRUE

quiet

Logical: suppress warning about non-positive values? DEFAULT: FALSE

...

further arguments passed to hist like breaks, xlim=c(-1,3), ..., but not xaxt

Value

none

Author(s)

Berry Boessenkool, berry-b@gmx.de, Feb 2016

See Also

logAxis, hist

Examples


dat <- rbeta(1e4, 2, 18)*100
hist(dat, col="tan", breaks=50)
logHist(dat)
logHist(dat, freq=FALSE)
logHist(dat, breaks=50)
logHist(dat,xlim=c(0,2)) # xlim in powers of ten
logHist(c(-1,0,1,2,2,3,3,4,8,10,50)) # warning for negative values


[Package berryFunctions version 1.20.1 Index]