Wiki Page, Math 13 - Perez Sandbox : Module 10 - Two-Way Tables (2 of 5)

Wiki Page
2026-01-17T21:15:08-08:00

A Relationship Between Two Categorical Variables

Now we analyze the relationship between two categorical variables. One variable is the explanatory variable. The explanatory variable defines the groups that we will compare. The other variable is the response variable. We analyze the distribution of the response variable for each group.

EXAMPLE Two-way table

If we separate our sample of 1,200 college students by gender and compare the male and female responses, will we find a similar distribution across body image categories? Or is there a difference based on gender?

Answering these questions requires us to examine the relationship between two categorical variables: gender and body image. We want to determine if gender explains the differences in body image responses. Therefore,

the explanatory variable is gender, and

the response variable is body image.

To summarize the relationship between two categorical variables, we create a display called a two-way table.

Here is the two-way table for our example:

Two-way table for body perception

| About Right | Overweight | Underweight | Row Totals
Female | 560 | 163 | 37 | 760
Male | 295 | 72 | 73 | 440
Column Totals | 855 | 235 | 110 | 1,200

Let’s take a closer look at this table:

The table helps us to compare females to males because there is a row for each gender. The body image categories are the columns. As we move across a particular row, all of the individuals are of the same gender. And as we move down a particular column, all of the individuals have the same body image.

We also added a column at the right for row totals, and we added a row at the bottom of the table for column totals. For example, look at the numbers in the Female row and note that there are 760 females in the sample (560 + 163 + 37 = 760). We also see in the About Right column that 855 of the students in the sample view their body weight as "about right."

Where a row and column cross, we see the number of individuals who fit both descriptions: a particular gender and a particular body image. It may be helpful to think of the six inner cells as six rooms filled with the 1,200 students from the sample. For example, in one room are the 72 males who think of themselves as overweight. In another room, we have 37 females who think of themselves as underweight. (Maybe they should have a potluck and get to know each other.)

Before we continue our analysis, we will pause to practice reading a two-way table in the next activity.