Frequency Distribution Calculator

Build grouped and ungrouped frequency distribution tables with histograms, cumulative frequencies, relative frequencies, and class count rule comparison.

About the Frequency Distribution Calculator

The frequency distribution calculator organizes raw data into a frequency table, either grouped into class intervals or left ungrouped as individual values. It can choose the number of classes automatically with Sturges' rule, the square root rule, or a custom count.

For each class, the calculator computes absolute frequency, relative frequency, cumulative frequency, and cumulative relative frequency. It also displays a histogram and ogive data so you can inspect the shape of the distribution and how values accumulate across the range.

Enter your raw data, pick a class-count method, and use the table to see where observations cluster, where gaps appear, and how the distribution changes when values are grouped into ranges.

Why Use This Frequency Distribution Calculator?

Use this calculator when a raw list of numbers needs to be turned into a readable summary. The grouped table is useful for continuous measurements, while the ungrouped table is better when there are only a few unique values.

The histogram and cumulative frequency data help you see both the overall shape and the running total of the distribution.

How to Use This Calculator

  1. Enter numbers separated by commas, spaces, or newlines (minimum 3 values).
  2. Select the number of classes: Auto (Sturges'), Square Root, or Custom.
  3. For custom, enter the desired number of classes.
  4. Review the grouped frequency table with class intervals, frequencies, and histogram bars.
  5. Check the ungrouped table (shown for ≤25 unique values) to see individual value counts.
  6. Compare class-count rules to decide if you want to adjust.
  7. Expand the ogive data section for cumulative frequency curve information.

Formula

Sturges' Rule: k = 1 + 3.322 log₁₀(n). Square Root: k = √n. Rice Rule: k = 2n^(1/3). Class width = Range / k (rounded up). Relative frequency = class frequency / n. Cumulative frequency = running total.

Example Calculation

Result: 5 classes, width 6.0, most frequent class: [73, 79) with 3 values

With 15 values, Sturges' rule gives k = 5 classes. Range = 95 − 67 = 28, class width = 6. The classes span from 67 to 97, with the most populated class containing 3 values (20% of data).

Tips & Best Practices

Grouped and Ungrouped Views

Ungrouped frequency tables count each distinct value. Grouped tables combine values into ranges, which is more useful when the dataset has many different measurements or when you need a compact summary.

Choosing Class Counts

The number of classes changes how much detail the table shows. Too many classes can hide the pattern in noise, while too few can hide important clusters. That is why the calculator compares simple class-count rules before building the table.

Reading the Distribution

Relative frequency shows the share in each class, cumulative frequency shows the running total, and the histogram gives a quick visual check of the shape. Together they provide a clear starting point for more detailed statistical analysis.

Sources & Methodology

Last updated:

Frequently Asked Questions

What is a frequency distribution?

A frequency distribution organizes data by counting how many values fall into each category or class interval. It transforms raw, unstructured data into a summary table that reveals the distribution shape — where values concentrate, how they spread, and whether there are gaps or clusters.

What's the difference between grouped and ungrouped frequency?

Ungrouped frequency counts each unique value individually (e.g., "the value 72 appears 3 times"). Grouped frequency combines values into ranges/classes (e.g., "70–79 has 5 values"). Use ungrouped for discrete data with few unique values; use grouped for continuous data or many unique values.

How do I choose the right number of classes?

Use Sturges' rule (1 + 3.322 log₁₀n) as a starting point. Adjust based on the resulting histogram: too few classes produce a flat, uninformative chart; too many make it spiky and noisy. For most practical work, 5–15 classes work well. Try different values and pick the one that best reveals the data's pattern.

What are relative and cumulative frequencies?

Relative frequency is the proportion: class freq / total n. It tells you what fraction of data falls in each class. Cumulative frequency is the running total: how many values are at or below that class. Cumulative relative frequency at the last class should equal 100%.

What is an ogive?

An ogive (cumulative frequency polygon) plots cumulative frequency against the upper class boundary. It's an S-shaped curve for normal data. You can read approximate percentiles directly from the ogive: find 50% on the y-axis and read the corresponding x-value for the median.

Can I use this for categorical data?

This calculator is designed for numerical (quantitative) data. For categorical data (colors, types, labels), a simple tally count works — you don't need class intervals or cumulative frequencies. Use a bar chart for categorical data visualization.

Related Pages