nclass.dhist: Density-based adaptive width histogram bins

Description Usage Arguments Value Author(s) References See Also Examples

Description

This algorithm has some notable advantages from a statistical point of view. Regions of high density have not only taller bins (as is usual) but more narrow bins as well. Regions of lower denisty have not only shorter, but wider bins. This makes the probability density much more immediately obvious, and captures interesting features of heavy tails and skew with greater efficacy. Algorithms that yield The former oversmooths in regions of high density, and is poor at identifying sharp peaks and multimodality. By contrast, the latter variety oversmooths in regions of low density and can mask outliers and the heavy tails of more leptokurtotic distributions. Alternatively, a function can be supplied which will compute the intended number of breaks or the actual breakpoints as a function of x. For more information, see Denby & Mallows (2009). The original code was authored by Lorraine Denby, but some minor improvements have been made here.

Usage

1
nclass.dhist(x, b = 1.5, rx = range(x), min.bins = NULL)

Arguments

b

slope. See paper for details. Defaults to 1.5.

rx

range of data, if not taken from data.

min.bins

the minimum number of bins. Optional.

nbins

number of bins. See Denby & Mallows (2009).

Value

A function that takes a single parameter, a numeric x specifying the data for which breaks are needed, and returns a vector of breaks.

Author(s)

Lorraine Denby, Brandon Vaughan

References

L. Denby and C. Mallows. Variations on the histogram. Journal of Computational and Graphical Statistics, 18 (1):21-31, 2009. URL http://pubs.amstat.org/doi/abs/10.1198/jcgs.2009.0002.

See Also

http://pubs.research.avayalabs.com/pdfs/ALR-2007-003-paper.pdf

Examples

1

abnormally-distributed/Bayezilla documentation built on Oct. 31, 2019, 1:57 a.m.