| 1 |
.\" RCSid "$Id: histo.1,v 1.3 2003/12/14 16:33:37 greg Exp $"
|
| 2 |
.TH HISTO 1 9/6/96 RADIANCE
|
| 3 |
.SH NAME
|
| 4 |
histo - compute 1-dimensional histogram of N data columns
|
| 5 |
.SH SYNOPSIS
|
| 6 |
.B "histo [-c][-p] xmin xmax nbins"
|
| 7 |
.br
|
| 8 |
.B "histo [-c][-p] imin imax"
|
| 9 |
.SH DESCRIPTION
|
| 10 |
.I Histo
|
| 11 |
bins columnular data on the standard input between the given minimum
|
| 12 |
and maximum values.
|
| 13 |
If three command line arguments are given, the third is taken as the
|
| 14 |
number of data bins between the first two real numbers.
|
| 15 |
If only two arguments are given, they are both assumed to be integers,
|
| 16 |
and the number of data bins will be equal to their difference plus one.
|
| 17 |
The bins are always of equal size.
|
| 18 |
.PP
|
| 19 |
The output is N+1 columns of data (for N columns input), where the
|
| 20 |
first column is the centroid of each division, and each row
|
| 21 |
corresponds to the frequencies for each column around that value.
|
| 22 |
.PP
|
| 23 |
If the
|
| 24 |
.I \-c
|
| 25 |
option is present, then
|
| 26 |
.I histo
|
| 27 |
computes the cumulative histogram for each column instead of the
|
| 28 |
straight frequencies.
|
| 29 |
The upper value of each bin is printed also instead of the centroid.
|
| 30 |
This may be useful in computing percentiles, for example.
|
| 31 |
Values below the minimum specified are still counted in the cumulative
|
| 32 |
total.
|
| 33 |
.PP
|
| 34 |
The
|
| 35 |
.I \-p
|
| 36 |
option tells
|
| 37 |
.I histo
|
| 38 |
to report the percentage of the total number of input lines rather
|
| 39 |
than the absolute counts
|
| 40 |
In the case of a cumulative total, this yeilds the percentile values
|
| 41 |
directly.
|
| 42 |
Values above the maximum are counted as well as values below in
|
| 43 |
this case.
|
| 44 |
.PP
|
| 45 |
All input data is interpreted as real values, and columns must be
|
| 46 |
white-space separated.
|
| 47 |
If any value is less than the minimum or greater than the maximum,
|
| 48 |
it will be ignored unless the
|
| 49 |
.I \-c
|
| 50 |
option is specified.
|
| 51 |
.SH EXAMPLE
|
| 52 |
To count data values between -1 and 1 in 50 bins:
|
| 53 |
.IP "" .2i
|
| 54 |
histo -1 1 50 < input.dat
|
| 55 |
.PP
|
| 56 |
To count frequencies of integers between 0 and 255:
|
| 57 |
.IP "" .2i
|
| 58 |
histo 0 255 < input.dat
|
| 59 |
.SH AUTHOR
|
| 60 |
Greg Ward
|
| 61 |
.SH "SEE ALSO"
|
| 62 |
cnt(1), neaten(1), rcalc(1), rlam(1), tabfunc(1), total(1)
|