Selecting a Categorical Procedure · 选择分类数据程序
Which categorical procedure?
- For categorical data, choose among proportion $z$-procedures and chi-square tests.
- The decision hinges on how many variables and how many samples.
- Get those right and the procedure follows.
- This skills lesson ties Units 6 and 8 together.
哪个分类程序?
- 对分类数据,在比例 $z$ 程序和卡方检验之间选择。
- 决策取决于有几个变量和有几个样本。
- 把这些弄对,程序就随之而来。
- 这节技能课把第 6 和第 8 单元串起来。
Count the variables and samples
- One variable, one sample, matched against a claimed distribution → goodness-of-fit.
- One variable, several separate samples → homogeneity.
- Two variables, one sample → independence.
- A single proportion (two categories, one sample) can also be a one-proportion $z$-test.
数变量和样本
- 一个变量、一个样本、对照宣称的分布 → 拟合优度。
- 一个变量、几个分开的样本 → 齐性。
- 两个变量、一个样本 → 独立性。
- 单个比例(两类、一个样本)也可以是单比例 $z$ 检验。
Chi-square vs. two-proportion z
- Comparing two groups on a two-category variable? Two valid options overlap here.
- A two-proportion $z$-test works and gives a direction (one-sided possible).
- A chi-square test of homogeneity also works (a $2\times2$ table) but is only non-directional.
- For a directional two-group proportion question, prefer the $z$-test.
卡方对两比例 z
- 在两组的一个两类别变量上比较?这里有两个有效选项重叠。
- 两比例 $z$ 检验可行,并给出方向(可单侧)。
- 齐性的卡方检验也可行(一个 $2\times2$ 表),但只能非方向性。
- 对有方向的两组比例问题,优先用 $z$ 检验。
Implement and communicate
- State hypotheses, check conditions, compute the statistic and p-value, conclude in context.
- Name the procedure explicitly and justify why it fits the data.
- Word the conclusion to match the test (fit / difference / association).
- Clear communication is graded as heavily as the arithmetic.
实施与沟通
- 陈述假设,检查条件,计算统计量和 p 值,结合语境下结论。
- 明确点名程序,并论证它为什么适合数据。
- 让结论的措辞匹配检验(拟合 / 差异 / 关联)。
- 清晰的沟通与算术同等重要地被评分。
Two questions pick the categorical procedure: how many VARIABLES, and how many SAMPLES. One variable vs. a claimed distribution → goodness-of-fit; one variable across several samples → homogeneity; two variables in one sample → independence. Chi-square is never directional — if you need a one-sided claim about two proportions, use the two-proportion $z$-test instead.
两个问题挑选分类程序:有几个变量,有几个样本。一个变量对照宣称的分布 → 拟合优度;一个变量跨几个样本 → 齐性;一个样本里两个变量 → 独立性。卡方永远不是方向性的——如果你需要关于两个比例的单侧主张,改用两比例 $z$ 检验。
"Do three schools have the same distribution of favorite sport?"
- Variables: one (favorite sport). Samples: three (separate schools).
- One variable, several samples → chi-square test of homogeneity.
- (Had it been "is sport related to gender in one survey?", → independence.)
“三所学校的最爱运动分布是否相同?”
- **变量:**一个(最爱运动)。**样本:**三个(分开的学校)。
- 一个变量、几个样本 → 齐性卡方检验。
- (若问的是“在一次调查中运动是否与性别相关?”,→ 独立性。)
Pick a categorical procedure by number of variables and number of samples: goodness-of-fit (one variable vs. a distribution), homogeneity (one variable, several samples), independence (two variables, one sample), or a proportion $z$-procedure. Implement fully and communicate the reasoning and conclusion in context.
按变量数和样本数挑选分类程序:拟合优度(一个变量对分布)、齐性(一个变量、几个样本)、独立性(两个变量、一个样本),或一个比例 $z$ 程序。完整地实施,并结合语境沟通推理与结论。
Categorical data to analyze · 待分析的分类数据
Count the variables and samples to pick the right test. · 数变量和样本来挑选正确的检验。
One categorical variable checked against a claimed distribution (one sample) calls for a... · 一个分类变量对照宣称分布(一个样本)需要……
One variable vs. a distribution → goodness-of-fit. · 一个变量对分布 → 拟合优度。
Three separately-sampled schools compared on one variable calls for a... · 三所分别抽样的学校在一个变量上比较,需要……
One variable, several samples → homogeneity. · 一个变量、几个样本 → 齐性。
Two variables recorded in ONE sample calls for a... · 在一个样本中记录两个变量,需要……
Two variables, one sample → independence. · 两个变量、一个样本 → 独立性。
A chi-square test can give a one-sided (directional) conclusion. · 卡方检验可以给出单侧(有方向)的结论。
Chi-square is never directional — use a two-proportion z-test for that. · 卡方永远非方向性——那种情况用两比例 z 检验。
Order the two questions that pick a categorical procedure, then the action. · 把挑选分类程序的两个问题、再加行动排序。
Variables, then samples, then run the procedure. · 先变量,再样本,然后执行程序。