qHist: Histogram with quantile line(s) and text(s)

View source: R/hist.R

qHistR Documentation

Histogram with quantile line(s) and text(s)

Description

A handy function to plot histogram with display elements of quantile.

Usage

qHist(x, quantiles = 0.25, breaks = 100, qlty = 2, qlwd = 2, qcol = "red", ...)

Arguments

x

Value to draw the histogram

quantiles

Numeric values or NULL; in case of numeric values, at the corresponding quantile values vertical lines and text labels are drawn; if set to NULL, no extra items will display. See examples below.

breaks

Integer, number of breaks

qlty

Type of vertical quantile lines

qlwd

Width of vertical quantile lines

qcol

Color of vertical quantile lines

...

Other parameters that are passed to hist

Details

The appends vertical lines and texts to histograms produced by hist. This can be useful in unspecific filtering of expression data.

Value

The object returned by the hist function, with an extra item named quantiles.

Author(s)

Jitao David Zhang <jitao_david.zhang@roche.com>

See Also

hist

Examples


testVal <- rnorm(1000)
hist(testVal)
qHist(testVal, quantiles=c(0.25, 0.75), border="lightgray")


bedapub/ribiosPlot documentation built on Sept. 1, 2023, 6:50 p.m.