.BG
.FN hist
.TL
Plot a Histogram
.CS
hist(x, nclass, breaks, plot=TRUE, probability=TRUE,
     angle, density, col, inside)
.AG x
numeric vector of data for histogram.
.NA
.AG nclass
optional recommendation for the number of classes (i.e., bars) the
histogram should have.
Default is of the order of log to the base 2 of length of `x'.
.AG breaks
optional vector of the break points for the bars of the histogram.
The count in the
.Co i -th
bar is
.Cs
sum( breaks[i] < x & x <= breaks[i+1] )
.Ce
If omitted, evenly-spaced break points
are determined from `nclass' and the extremes of the data.
.AG plot
if `TRUE', the histogram will be plotted;
if `FALSE', a list giving breakpoints and counts will be returned.
.AG probability
if `TRUE', the histogram is scaled as a probability density --
the sum of the bar heights times bar widths equals 1;
if `FALSE', the bar heights are counts.
.PP
The `hist' function uses the function `barplot' to do the
actual plotting.
Consequently, arguments to the `barplot' function that control shading, etc.,
can also be given to `hist'.
See `barplot' documentation for arguments
`angle', `density', `col',  and `inside'.
.GR
.RT
if `plot' is `FALSE', `hist' returns a list
with components:
.RC counts
count or density in each bar of the histogram.
.RC breaks
break points between histogram classes.
.EX
# the example plot is produced by:
my.sample <-  rt(50,5)
lab <- "50 samples from a t distribution with 5 d. f."
hist(my.sample,main=lab)
.PI
.KW hplot
.KW dplot
.WR
