Download presentation
Presentation is loading. Please wait.
1
Displaying and Describing Categorical Data
Lecture 3 Displaying and Describing Categorical Data Copyright © Pearson Education.
2
Summarizing a Categorical Variable
QTM1310/ Sharpe Summarizing a Categorical Variable The Three Rules of Data Analysis Make a picture. Make a picture. Make a picture. Pictures … reveal things that can’t be seen in a table of numbers. show important features and patterns in the data. provide an excellent means for reporting findings to others. 2
3
Summarizing a Categorical Variable
QTM1310/ Sharpe Summarizing a Categorical Variable A frequency table organizes data by recording totals and category names as in the table below. The names of the categories label each row in the frequency table. When the number of categories gets too large (around 12), values may be lumped together in an “Other” category. 3
4
Summarizing a Categorical Variable
QTM1310/ Sharpe Summarizing a Categorical Variable A relative frequency table displays the percentages that lie in each category rather than the counts. (See the table below.) The percentage of the data in each category is found by dividing the count in each category by the total number of cases and multiplying by 100. 4
5
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable The Area Principle The figure given distorts the data from the frequency tables seen in previous slides (which was data based on internet sandal sales). Though the length of the sandals do match the data, our eyes tend to be impressed by the area which can be misleading. 5
6
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable The Area Principle The best data displays observe the area principle: the area occupied by a part of the graph should correspond to the magnitude of the value it represents. 6
7
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable Bar Charts A bar chart displays the distribution of a categorical variable, showing the counts for each category next to each other for easy comparison. The bar graph here gives a more accurate visual impression of the sandal data. 7
8
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable Bar Charts If the counts are replaced with percentages, the data can be displayed in a relative frequency bar chart. The relative frequency bar chart looks the same as the bar chart, but shows the proportion of visits in each Category rather than counts. 8
9
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable Pie Charts Pie charts show the whole group of cases as a circle sliced into pieces with sizes proportional to the fraction of the whole in each category. The KEEN Inc. data is displayed below. 9
10
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable Before making a bar chart or pie chart, … the data must satisfy the Categorical Data Condition: the data are counts or percentages of individuals in categories. be sure the categories don’t overlap. consider what you are attempting to communicate about the data. 10
11
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable Example: U.S. Market Share An article in The Wall Street Journal (March 16, 2007) reported the 2006 U.S. market share of leading sellers of carbonated drinks, summarized in the following pie chart. Is this an appropriate display for these data? Explain. Which company had the largest share of the market? 11
12
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable Example: U.S. Market Share An article in The Wall Street Journal (March 16, 2007) reported the 2006 U.S. market share of leading sellers of carbonated drinks, summarized in the following pie chart. Yes this is an appropriate display for these data because the categories divide the whole. Coca-Cola had the largest share of the market. 12
13
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable Example: U.S. Market Share An article in The Wall Street Journal (March 16, 2007) reported the 2006 U.S. market share of leading sellers of carbonated drinks, summarized in the bar chart below. Compare to the previously shown pie chart. Which is better for displaying the relative portions of market share? What is missing from this display that might make it misleading? 13
14
Displaying a Categorical Variable
QTM1310/ Sharpe Displaying a Categorical Variable Example: U.S. Market Share An article in The Wall Street Journal (March 16, 2007) reported the 2006 U.S. market share of leading sellers of carbonated drinks, summarized in the bar chart below. Compare to the previously shown pie chart. The pie chart is better for displaying the relative portions of market share. The category “Other” is missing from this display which might make the graph misleading. 14
15
Exploring Two Categorical Variables: Contingency Tables
QTM1310/ Sharpe Exploring Two Categorical Variables: Contingency Tables Example: Data was collected on the strength of consumers’ preferences for regional foods in their country. The data is displayed in the frequency table and clarified with a pie chart. 15
16
Exploring Two Categorical Variables: Contingency Tables
QTM1310/ Sharpe Exploring Two Categorical Variables: Contingency Tables To show how opinions on regional foods varied by countries, we can display the data in a contingency table where we have added the countries as a new variable. 16
17
Exploring Two Categorical Variables: Contingency Tables
QTM1310/ Sharpe Exploring Two Categorical Variables: Contingency Tables The marginal distribution of a variable in a contingency table is the total count that occurs when the value of that variable is held constant. Here the marginal distribution indicated shows that there were 1502 respondents from China. 17
18
Exploring Two Categorical Variables: Contingency Tables
QTM1310/ Sharpe Exploring Two Categorical Variables: Contingency Tables Each cell of a contingency table (any intersection of a row and column of the table) gives the count for a combination of values of the two variables. Here the indicated cell shows that 4 respondents from India didn’t know how they felt about the question asked. 18
19
Exploring Two Categorical Variables: Contingency Tables
QTM1310/ Sharpe Exploring Two Categorical Variables: Contingency Tables Rather than displaying the data as counts, a table may display the data as a percentage – as a total percent, row percent, or column percent, which show percentages with respect to the total count, row count, or column count, respectively. We see that 6.74% of all respondents were from China and agreed completely with the question asked. 19
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.