✦Template Printable Ideas Insights

Contingency Table Example Problems

By

A contingency table, also known as a two-dimensional frequency distribution table, is a statistical tool used to represent the frequencies of different variables in a categorical format. It helps us understand the relationship between two categorical variables by showing the distribution of each variable's categories and their intersections. In this article, we will delve into contingency table examples and problems, providing a comprehensive understanding and practical applications.

Contingency tables are widely used in hypothesis testing, association rule mining, and exploratory data analysis. They are particularly useful when dealing with nominal and ordinal data. Before we dive into examples, let's quickly recap the structure of a contingency table.

Understanding the Structure of a Contingency Table

A typical contingency table includes rows and columns, each representing different categories of the two variables being analyzed. The values in the table are frequencies, meaning the number of observations that fall into each category combination. The margins (sum of row or column values) represent the total number of observations for each of the single variable, while the grand total is the overall sample size.

What are Contingency Tables and Why Do You Need To Use Them?
What are Contingency Tables and Why Do You Need To Use Them?
Function Tables free worksheets
Function Tables free worksheets
Making sure you're not a bot!
Making sure you're not a bot!

Now that we have a basic understanding, let's explore two common use cases with examples.

Example 1: Analyzing Smoking and Lung Cancer

Let's consider a study investigating the relationship between smoking (yes/no) and lung cancer (yes/no) in a sample of 1,000 individuals:

Problem Solving in Math
Problem Solving in Math
Input/Output Tables -- Addition Facts 1 to 9 -- Output Only Blank (A)
Input/Output Tables -- Addition Facts 1 to 9 -- Output Only Blank (A)
Continuous addition task 3 (20 sheets)
Continuous addition task 3 (20 sheets)
Lung CancerNo Lung CancerTotal
Smokers150500650
Non-smokers50300350
Total2008001,000

One can visualize that smokers are more likely to develop lung cancer than non-smokers. The risk ratio is (150/650) / (50/350) = 3.2, indicating a strong association between smoking and lung cancer.

Example 2: Age and Vehicle Ownership

Now let's examine the relationship between age groups (18-25, 26-35, 36-45, 56+) and vehicle ownership (car/motorcycle/none) among 800 individuals:

CarMotorcycleNoneTotal
18-25250150100500
26-354005050500
36-453002030350
56+1501070230
Total1,1002302501,580

From this table, we can infer that vehicle ownership varies significantly across age groups. For instance, the youngest group (18-25) has the highest motorcycle ownership, while the middle-aged group (26-35) has the highest car ownership.

DAY 3 : PROBLEM SOLVING
DAY 3 : PROBLEM SOLVING
three lines that are parallel to each other, with the same line going through them
three lines that are parallel to each other, with the same line going through them
Example: Risks & Controls Table. Periodic Table
Example: Risks & Controls Table. Periodic Table
CHEMISTRY Practice: Single Replacement Reactions with ANSWER KEY! Great for homeschooling / homework
CHEMISTRY Practice: Single Replacement Reactions with ANSWER KEY! Great for homeschooling / homework
Continuous calculation task ( subtraction to addition)
Continuous calculation task ( subtraction to addition)
Miss B 123
Miss B 123

Challenges and Solutions in Contingency Tables

Contingency tables, while insightful, pose some challenges. Small cell frequencies and high dimensionality can lead to decreased statistical power and increased probability of spurious findings. Here are two solutions to these challenges:

Solution 1: Collapsing Categories

When dealing with small cell frequencies, one common technique is to collapse categories. For instance, in our lung cancer example, we could combine "yes" into a single category, resulting in a 2x2 table, making statistical analysis more robust.

Solution 2: Resampling Techniques

Resampling techniques, such as bootsstrapping, can help address high-dimensionality issues. By resampling with replacement, we create new datasets and thereby stabilize the estimates, providing more reliable results.

a diagram with the words problem of the day on it
a diagram with the words problem of the day on it
Continuous calculation task (addition to subtraction)
Continuous calculation task (addition to subtraction)
the worksheet for trains problems is shown in red and blue, with an image of
the worksheet for trains problems is shown in red and blue, with an image of

In exploring contingency table examples, we've demonstrated their applicability across different scenarios. Whether investigating disease risk factors, market trends, or academic performance, understanding the relationship between variables is key. By now, you're equipped with the skills to create, interpret, and analyze contingency tables.