Marginal and conditional distributions

    Understanding Bivariate Data with Categorical Variables

    When analyzing the relationship between two categorical variables, we often use a two-way table (also known as a contingency table). This table displays the counts (frequencies) or percentages of observations for each combination of categories for the two variables.

    Marginal Distributions

    A marginal distribution of a categorical variable in a two-way table is the distribution of values of that variable among all individuals described by the table. It tells us about the overall prevalence of each category for one variable, ignoring the other variable.

    • To find a marginal distribution, we look at the row totals or column totals in the two-way table.
    • These totals represent the frequency of each category for one variable across all categories of the other variable.
    • Marginal distributions are typically expressed as percentages of the grand total.

    Example: Marginal Distribution of Gender

    Consider a survey on preferred ice cream flavors (Vanilla, Chocolate) by Gender (Male, Female).

    Vanilla Chocolate Total (Gender) Male 50 70 120 Female 80 100 180 Total (Flavor) 130 170 300 (Grand Total)

    The marginal distribution of Gender would be: Male = 120/300 = 40%, Female = 180/300 = 60%.

    Conditional Distributions

    A conditional distribution of a variable describes the values of that variable among individuals who have a specific value of another variable. In simpler terms, it's the distribution of one variable for only one specific category of the other variable.

    • Conditional distributions are calculated within a specific row or column.
    • They are always expressed as percentages, where the denominator is the total for the specific condition (the row or column total for that category).
    • Comparing conditional distributions helps us determine if there is an association between the two variables. If the conditional distributions are notably different, there's likely an association. If they are very similar, there might be little or no association.

    Example: Conditional Distribution of Flavor given Gender

    Using the same table:

    • Conditional distribution of Flavor for Males:
      Vanilla: 50/120 ≈ 41.7%
      Chocolate: 70/120 ≈ 58.3%
    • Conditional distribution of Flavor for Females:
      Vanilla: 80/180 ≈ 44.4%
      Chocolate: 100/180 ≈ 55.6%

    Comparing these, we can see that males are slightly more likely to prefer chocolate (58.3%) than females (55.6%), and females are slightly more likely to prefer vanilla (44.4%) than males (41.7%). These differences suggest a slight association between gender and preferred ice cream flavor.

    Identifying Association

    To determine if there is an association between two categorical variables, we compare their conditional distributions. If the conditional distributions are not similar, then there is evidence of an association between the variables. If they are very similar, it suggests independence (no association).

    Graphical displays like segmented bar graphs or side-by-side bar graphs are excellent tools for visually comparing conditional distributions and identifying associations.

    Practice questions

    1

    What does a marginal distribution describe in a two-way table?

    2

    How do you calculate a conditional distribution for a specific category?

    3

    What is the primary purpose of comparing conditional distributions?

    4

    Consider a two-way table showing student enrollment (full-time, part-time) by major (Arts, Sciences). If the percentage of full-time students is significantly higher in Sciences than in Arts, what does this indicate?

    Practice more free →

    Free AP4U account — unlimited practice, AI grader, and progress tracking.

    Canonical: https://apforu.com/ap/statistics/unit-2-exploring-two-variable-data/marginal-and-conditional-distributions