A contingency table, also known as a cross tabulation or crosstab, is a type of table in statistics that displays the frequency distribution of the variables. It helps in analyzing the relationship between two or more categorical variables. The table is typically used to summarize and compare the relationships within the data.
Here’s a basic structure of a contingency table:
- Dimensions: It usually involves two or more categorical variables. For example, a contingency table might relate to two variables like ‘Gender’ (Male, Female) and ‘Preference’ (Likes, Dislikes).
- Cells: Each cell in the table shows the count or frequency of occurrences for a specific combination of categories from the variables.
- Margins: The table often includes row totals and column totals, known as marginal totals, which provide the total counts across a row or column.
- Use in Statistics: Contingency tables are used for various statistical methods, including calculating probabilities, chi-squared tests, and other hypothesis tests to determine whether there’s a significant association between the variables.
For example, a simple 2×2 contingency table might look like this:
Gender | Likes | Dislikes | Total |
---|---|---|---|
Male | 20 | 30 | 50 |
Female | 25 | 25 | 50 |
Total | 45 | 55 | 100 |
This table shows the relationship between gender and preference, with each cell indicating the count of individuals with each combination of characteristics.