Analyse-it
Analyse-it
  • Products
  • Pricing
  • Support
  • About us
Download trial Sign in
  • Tutorials
  • Association in 2-way contingency tables tutorial

Cross tabulation of the data

When two variables are measured the relationship between them is often of interest. A contingency table describes the joint distribution of the variables. It can also describe the marginal distributions of each variable, or the conditional distribution of one variable given the other.

  1. Open the file tutorials\Hair-Eye Color.xlsx.
  2. Click a cell in the dataset.
  3. On the Analyse-it ribbon tab, in the Statistical Analyses group, click Compare Groups, and then click Contingency Table.
    The analysis task pane opens.
  4. In the Y (response) variable drop-down list, select Hair.
  5. In the X (factor) variable drop-down list, Select Eye.
  6. In the Model: Y by X drop-down list, select Frequency
  7. In the Frequency variable drop-down list, select Count.
  8. On the Analyse-it ribbon tab, in the Compare Groups group, click Test Proportion > Pearson X2.

    A Pearson X2 hypothesis test is added to the analysis task pane.

  9. In the Hypothesis drop-down list, select The variables are not independent as the alternative hypothesis .
  10. In the Significance level edit box, enter 5%.
  11. Click Calculate.
    The results are calculated and the analysis report opens.

The contingency table shows the joint distribution of the variables.

contingency table

The hypothesis test p-value is highlighted as it is less than 5% significance level (the actual p-value is < 0.0001). You can interpret the p-value as indicating a substantial departure from independence.

chi-square test
Next topic: Displaying patterns of association

  •  Tutorials
  •  Distribution tutorial
  •  Correlation / PCA tutorial
  •  Compare groups means tutorial
  •  Association in 2-way contingency tables tutorial
  •  Cross tabulation of the data
  •  Displaying patterns of association
  •  Reordering data
  •  Simple linear regression tutorial
  •  Bland-Altman method comparison tutorial
  •  Estimating the precision of a measurement procedure (CLSI EP05-A3)
  •  Evaluating the linearity of a measurement procedure (CLSI EP06-A)
  •  Verifying the precision of a measurement procedure against a performance claim and estimating the bias (CLSI EP15-A3)
  •  Pareto charts tutorial
  •  Process control charts tutorial
  •  Process capability tutorial



Version 6.15
Published 18-Apr-2023
Products
  • Standard Edition
  • Medical Edition
  • Quality Control & Improvement Edition
  • Method Validation Edition
  • Ultimate Edition
  • Compare Editions
  • Pricing
Support
  • Documentation
  • Tutorials
  • Download latest version
  • Release history
  • Contact support
Company
  • About us
  • Blog
  • Contact us
  • Privacy policy

Get Started

  • Download free trial
  • Sign In

© 2026 Analyse-it® Software, Ltd. All rights reserved.

Statistical analysis and method validation software for Microsoft Excel.

We use essential cookies to run the site, and optional analytics to improve the experience for visitors. For more information see our Privacy policy.