SBHistogram

(c) Scott M Baker, http://www.sb-software.com


SBHistogram is a very simple program for generating histograms. There hasn't been a whole lot of work put into ensuring it works correctly, so use at your own risk.

What is a histogram ?

A histogram is a chart in which data values in counted and placed into buckets. For example, let's assume you want to do a histogram of peoples ages. Then you might want to use buckets such as 1-10 years, 11-20 years, 21-30 years, etc. Each bucket counts the number of data items that fall into it's range. The buckets are then displayed in a bar chart.

Input Files:

SBHistogram expects your input file to be a plain ascii text with one histogram item per line. There can be additional "junk" on the line after the data value, but the data value must be the first thing that appears on each text line.

Example:

123
456
111
222

The histogram can contain either numbers (as in the example above) or text strings. If you want to use text strings, then you'll need to check the option "values are strings not integers" on the main window.

Running the program:

Enter the input file name, bucket size, etc and then click the <Run> button.

NOTE: for large data files, the program will be *** Unresponsive *** while it reads the data file. i.e. it will appear as if the program has frozen. However, it will eventually wake back up when it has finished reading the file.

Output:

SBHistogram will output either text files or BMP images of the histogram graph.

Options:

Numeric or String Histograms

The checkbox "Values are *Strings* not integers" is used to decide if you want a numeric histogram or a string histogram. A numeric histogram is used for data that contains intergers (i.e. "123", "456", etc). A string histogram is used for data that contains strings (i.e. "foo", "bar", etc).

The following four options are for numeric (i.e. not "string" histograms) only:

Bucket Count: the number of histogram bars that will be on the histogram graph

Bucket Size: the number of data values that ae represented by a histogram bar

Starting Bucket: the first histogram bar will start with this value

Include buckets with count zero: If this is checked, then empty buckets will be displayed in the graph. Including empty buckets is usually desired as it allows the x-axis of the graph to be proportional. If you turn off empty buckets, then the X-axis will "skip" those buckets that are empty.


Contacting the author:

you can reach me at http://www.sb-software.com