Cross Tabulation

Statistics > Basic Statistics > Cross Tabulation

 

Produces a table of counts for all combinations of specified variables

Cross Tabulations are used to count the number of cases that have different combinations of values of two or more variables, and to calculate summary statistics and tests.

 

Dialog box items

Categorical Variables

oRows: Select the variables displayed in rows in the crosstabulation. Selected variables should be factors. A crosstabulation is produced for each combination of row and column variables.

oColumns: Select the variables displayed in columns in the crosstabulation. Selected variables should be factors. A crosstabulation is produced for each combination of row and column variables.

oLayers (optional): Select the columns containing the categories that define the layers of the two-way tables.

Display Summaries for

oSummaries (optional): Select the numeric variable to be summarized. The default summary function is mean. To change the summary function, select the Statistics tab.

Report:
The display of outputs of VisualStat.

 

Data

To use Cross Tabulation, your data should be categorical. To define the categories of each table variable, use values of a numeric or short string (eight or fewer characters) variable. For example, for gender, you could code the data as 1 and 2 or as male and female.

 

Cell Display

Each cell of the table can contain any combination of counts, percentages, and residuals selected.

Percentages
The percentages can add up across the rows or down the columns. The percentages of the total number of cases represented in the table (one layer) are also available.

oRows: Check to display the percentage each cell represents of the total observations in the table row.

oColumns: Check to display the percentage each cell represents of the total observations in the table column.

oTotal: Check to display the percentage each cell represents of all the observations in the table.

Residuals

oExpected Count: Check to display each cell's expected count.

oRaw Residuals: Check to display the difference between the observed and the expected count in each cell.

oStandardized Residuals: Check to display the standardized residuals of each cel. Standardized residuals are the raw residuals divided by the square root of the expected counts.

oCell Contribution to the Chi-Square: Check to display each cell's contribution to the overall chi-square statistic.

 

Statistics

The display of univariate statistics.

 

Charts

Displays a bar chart or a line chart.

Chart Type:
Choose from the following options:

oNone: Choose to do nothing

oBar: Choose to display a bar chart for each variable.
A bar chart displays the count (or percentage) for each distinct value or category as a separate bar, allowing you to compare categories visually.

oLine: Choose to display a line chart for each variable

Chart Values:
Choose the type of axis label you want

oCount: Choose if bars (or lines) represent counts of unique values

oPercentage: Choose if bars (or lines) represent percentages

Options:
Choose the options you want.

oShow ToolTip: Check to displays tooltip text when you point the chart.

oShow Data Labels: Check to label each data point with its y-axis value.

 

Example of Cross Tabulation with Cell Percentages

Subjects were students in grades 4-6 from three school districts in Ingham and Clinton Counties, Michigan. Chase and Dummer stratified their sample, selecting students from urban, suburban, and rural school districts with approximately 1/3 of their sample coming from each district. Students indicated whether good grades, athletic ability, or popularity was most important to them. They also ranked four factors: grades, sports, looks, and money, in order of their importance for popularity. The questionnaire also asked for gender, grade level, and other demographic information.

Source: http://lib.stat.cmu.edu/DASL/Datafiles/PopularKids.html

1.Open the DataBook summary.vstz

2.Select the sheet PopularKids

3.Choose the tab Statistics, the group Basic Statistics and the command Cross Tabulation

4.Select group Categorical Variables

5.In Rows, select Gender. In Columns, select Grade

6.Click Cell Display page.

7.In group box Percentages, check Row, Column, and Total.

8.Click OK

 

Report window output

 

Cross Tabulation

 

Row: Gender          Column: Grade

               4         5         6   Overall

                                           

boy            54        86        87       227

         23.7885   37.8855   38.3260  100.0000

         45.3782   48.8636   47.5410   47.4895

         11.2971   17.9916   18.2008   47.4895

                                           

girl           65        90        96       251

         25.8964   35.8566   38.2470  100.0000

         54.6218   51.1364   52.4590   52.5105

         13.5983   18.8285   20.0837   52.5105

                                           

Overall       119       176       183       478

         24.8954   36.8201   38.2845  100.0000

        100.0000  100.0000  100.0000  100.0000

         24.8954   36.8201   38.2845  100.0000

 

Cell Contents:

        Count

        % of Row

        % of Column

        % of Total

 

 

 

Example of Cross Tabulation with three Categorical Variables

You would like to classify the individuals in your study by Gender, Grade and Urban/Rural.

1.Open the DataBook summary.vstz

2.Select the sheet PopularKids

3.Choose the tab Statistics, the group Basic Statistics and the command Cross Tabulation

4.Select group Categorical Variables

5.In Rows, select Gender. In Columns, select Grade. In Layers (optional), select Urban/Rural

6.Click OK

 

Report window output

 

Cross Tabulation

 

Results for Urban/Rural = Rural

 

Row: Gender          Column: Grade

         4   5   6  Overall

boy      16  24  26       66

girl     28  29  26       83

Overall  44  53  52      149

 

Cell Contents:

        Count

 

 

Results for Urban/Rural = Suburban

 

Row: Gender          Column: Grade

         4   5   6  Overall

boy      14  29  46       89

girl      8  17  37       62

Overall  22  46  83      151

 

Cell Contents:

        Count

 

 

Results for Urban/Rural = Urban

 

Row: Gender          Column: Grade

         4   5   6  Overall

boy      24  33  15       72

girl     29  44  33      106

Overall  53  77  48      178

 

Cell Contents:

        Count

 

 

Interpreting the results

In this layout, VisualStat creates a two-way table for each level of the layering variable, Urban/Rural. The row variable is Gender and the column variable is Grade. It may be easier for you to compare your data in a different layout. You can change your table layout by designating variables to be across rows, down columns, or as layers.

 

 

 

 

Example of Cross Tabulation with Summary Statistics

You want to compare the score of male and female students by levels of grade.

1.Open the DataBook summary.vstz

2.Select the sheet PopularKids

3.Choose the tab Statistics, the group Basic Statistics and the command Cross Tabulation

4.Select group Categorical Variables

5.In Rows, select Gender. In Columns, select Grade.

6.Select group Display Summaries for

7.In Summaries (optional), select Age.

8.Click Statistics page. Check Mean and Standard Deviation

9.Click OK

 

 

Report window output

 

Cross Tabulation

 

Row: Gender          Column: Grade

             4        5        6  Overall

                                       

boy          54       86       87       227

        9.2593  10.3837  11.4598  10.5286

        0.4786   0.5534   0.5633   1.0078

                                       

girl         65       90       96      251

        9.0923  10.3111  11.1771  10.3267

        0.4196   0.5301   0.4081   0.9388

                                       

Overall     119      176      183      478

        9.1681  10.3466  11.3115  10.4226

        0.4550   0.5428   0.5081   0.9774

 

Cell Contents:

        Count

        Mean of Age

        Standard Deviation of Age

 

 

 

See Also:


Report | Numeric Formats