StatsCalculators.com

Frequency Table

Created:September 15, 2024
Last Updated:July 26, 2025

This calculator creates a structured table showing how often values appear in your dataset. It displays the frequency (count), cumulative frequency, percentage (relative frequency), and cumulative percentage (cumulative relative frequency) of each unique value, helping you identify patterns and distributions in your data. You can choose how categories are sorted (alphabetically, by weekday, by month, numerically, or in a custom order you define) to best represent your data. A bar chart is also included to better understand your data's distribution.

Related tools you might find useful:

  • Histogram - Grouped frequency table for numeric data with ranges (0-10, 11-20, etc.)
  • Contingency table - Two way frequency table between two categorical variables
  • Pivot table - Custom aggregations (count, sum, etc.) for multiple categorical variables and a numeric variable

Quick Calculator

Need a quick calculation? Enter your numbers below:

Calculator

1. Load Your Data

Note: Column names will be converted to snake_case (e.g., "Product ID" → "product_id") for processing.

2. Select Columns & Options

Related Calculators

Learn More

What is a Frequency Table?

Definition

A frequency table (also called a frequency distribution table) is a statistical tool that organizes data by displaying how often each distinct value or category occurs in a dataset. It provides a structured way to summarize data distribution through counts, percentages, and cumulative frequencies.

When to Use Frequency Tables

Categorical Data:

  • Survey responses (Yes/No/Maybe)
  • Product categories
  • Geographic regions
  • Educational levels

Discrete Numerical Data:

  • Number of children in families
  • Days of the week
  • Exam grades (A, B, C, D, F)
  • Rating scales (1-5 stars)

Types of Frequency Tables

Simple Frequency Table

Shows frequency and relative frequency for a single variable.

Color | Frequency | %
Red | 15 | 30%
Blue | 25 | 50%
Green | 10 | 20%

Two-Way Frequency Table

Shows relationship between two categorical variables.

Gender | Male | Female
Coffee | 20 | 15
Tea | 10 | 25

Grouped Frequency Table

Groups continuous data into intervals or ranges.

Age Range | Frequency
18-25 | 12
26-35 | 18
36-45 | 15

Cumulative Frequency Table

Includes running totals to show cumulative distribution.

Score | Freq | Cumulative
A | 10 | 10
B | 15 | 25
C | 20 | 45

Understanding Frequency Table Components

Frequency (Count)

The number of times each value appears in your dataset.

Relative Frequency (%)

The percentage each value represents of the total dataset.

Formula: (Frequency ÷ Total) × 100

Cumulative Frequency

Running total of frequencies up to and including the current value.

Cumulative Percentage

Running total of relative frequencies, useful for percentiles.

How to Make a Frequency Table (Step-by-Step)

Manual Method

  1. Collect your data: Gather all values you want to analyze
  2. Identify unique values: List all distinct categories or values
  3. Count frequencies: Tally how many times each value appears
  4. Calculate percentages: Divide each frequency by total and multiply by 100
  5. Add cumulative columns: Calculate running totals if needed
  6. Sort appropriately: Order by frequency, alphabetically, or logically

Example: Survey Responses

Raw data: Red, Blue, Red, Green, Blue, Blue, Red, Green, Blue, Red

Color
Frequency
Percentage
Cumulative %
Blue
4
40%
40%
Red
4
40%
80%
Green
2
20%
100%

Academic Example: Final Exam Scores Distribution

Distribution of final exam scores for 100 students in a statistics course.

Score Distribution

Score RangeGradeFrequencyPercentageCumulative %
90-100A1515.0%15.0%
80-89B2525.0%40.0%
70-79C3535.0%75.0%
60-69D2020.0%95.0%
Below 60F55.0%100.0%

Grade Distribution

Key Insights:

  • Mode: Grade C (Most common grade)
  • 40% of students received grades B or higher
  • Only 5% of students failed the exam
  • The distribution shows a roughly normal curve

This frequency table helps instructors understand the overall class performance, identify areas for improvement, and compare with expected grade distributions.

Creating Frequency Tables in Different Tools

Examples of how to create frequency tables in R, Python, and Excel.

R (tidyverse)

R
# Enhanced R frequency table with multiple sorting options
library(tidyverse)

data <- c("Red", "Blue", "Red", "Green", "Blue", "Blue", "Red", "Green", "Blue", "Red")

# quick and simple way
table(data)

# create comprehensive frequency table
freq_table <- data.frame(value = data) |>
  count(value, name = "frequency") |>
  mutate(
    percentage = round(frequency / sum(frequency) * 100, 1),
    cumulative_freq = cumsum(frequency),
    cumulative_pct = round(cumsum(percentage), 1)
  ) |>
  arrange(desc(frequency))  # Sort by frequency (most common first)

print(freq_table)

# visualization
ggplot(freq_table, aes(x = reorder(value, frequency), y = frequency)) +
  geom_col(fill = "steelblue", alpha = 0.8) +
  geom_text(aes(label = frequency), hjust = -0.1) +
  coord_flip() +
  labs(title = "Frequency Distribution", 
       x = "Category", y = "Frequency") +
  theme_minimal()

Python (pandas)

Python
import pandas as pd
import matplotlib.pyplot as plt

# Sample data
data = ["Red", "Blue", "Red", "Green", "Blue", "Blue", "Red", "Green", "Blue", "Red"]
df = pd.DataFrame({'color': data})

# Create frequency table
freq_table = df['color'].value_counts().reset_index()
freq_table.columns = ['Category', 'Frequency']
freq_table['Percentage'] = round(freq_table['Frequency'] / len(data) * 100, 1)
freq_table['Cumulative_Freq'] = freq_table['Frequency'].cumsum()
freq_table['Cumulative_Pct'] = freq_table['Percentage'].cumsum()

print(freq_table)

# Simple bar chart
freq_table.plot(x='Category', y='Frequency', kind='bar')
plt.title('Frequency Distribution')
plt.show()

Excel

Excel
=COUNTIF($A$1:$A$100,B1)

Method 1: COUNTIF Function

Use =COUNTIF($A$1:$A$100,B1) to count how many times the value in B1 appears in your data range.

Method 2: Pivot Table

  1. Select your data range
  2. Go to Insert → PivotTable
  3. Drag your category field to Rows
  4. Drag the same field to Values (it will count automatically)
  5. To add percentages, right-click a value in the PivotTable, choose Show Values As % of Column Total