1 / 18

If we live with a deep sense of gratitude, our life will be greatly embellished.

If we live with a deep sense of gratitude, our life will be greatly embellished. Categorical Data Analysis. Chapter 10: Tests for Matched Pairs. Meta Analysis. Also known as stratified analysis Section 6.3.2: Cochran-Mantel-Haenszel test; test for conditional independence

cooperr
Download Presentation

If we live with a deep sense of gratitude, our life will be greatly embellished.

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. If we live with a deep sense of gratitude, our life will be greatly embellished.

  2. Categorical Data Analysis Chapter 10: Tests for Matched Pairs

  3. Meta Analysis • Also known as stratified analysis • Section 6.3.2: Cochran-Mantel-Haenszel test; test for conditional independence Situation: When another variable (strata Z) may “pollute” the effect of a categorical explanatory variable X on a categorical response Y Goal: Study the effect of X on Y while controlling the stratification variable Z without assuming a model

  4. Example: Respiratory Improvement (SAS textbook, P. 46)

  5. SAS Output Summary Statistics for trtmnt by response Controlling for center Cochran-Mantel-Haenszel Statistics (Based on Table Scores) Statistic Alternative Hypothesis DF Value Prob ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ 1 Nonzero Correlation 1 18.4106 <.0001 2 Row Mean Scores Differ 1 18.4106 <.0001 3 General Association 1 18.4106 <.0001

  6. What to Do if Dependent • (Section 6.3.5) When X and Y are NOT conditionally independent given Z, we would like to test for homogeneous association • (Section 6.3.6) If X, Y, Z have homogeneous association, we would like to estimate the common conditional odds ratio for X, Y given Z

  7. SAS Output Estimates of the Common Relative Risk (Row1/Row2) Type of Study Method Value 95% Confidence Limits ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ Case-Control Mantel-Haenszel 4.0288 2.1057 7.7084 (Odds Ratio) Logit 4.0286 2.1057 7.7072 Cohort Mantel-Haenszel 1.7368 1.3301 2.2680 (Col1 Risk) Logit 1.6760 1.2943 2.1703 Cohort Mantel-Haenszel 0.4615 0.3162 0.6737 (Col2 Risk) Logit 0.4738 0.3264 0.6877 Breslow-Day Test for Homogeneity of the Odds Ratios ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ Chi-Square 0.0002 DF 1 Pr > ChiSq 0.9900 Total Sample Size = 180

  8. Matched-pair Data • Comparing categorical responses for two “paired” samples When either • Each sample has the same subjects (or say subjects are measured twice) Or • A natural pairing exists between each subject in one sample and a subject from the other sample (eg. Twins)

  9. Example: Rating for Prime Minister

  10. Marginal Homogeneity • The probabilities of “success” for both samples are identical (The data table shows “symmetry” across the main diagonal) • Eg. The probability of approve at the first and 2nd surveys are identical

  11. Estimating Differences of Proportions • Sample estimate: P+1-P1+ • Standard error of P+1-P1+ (based on the multinomial distribution of data): • Asymptotical (1-a) confidence interval:

  12. McNemar Test (for 2x2 Tables only) • See SAS textbook Sec 3.7 (p. 40) • Ho: marginal homogeneity Ha: no marginal homogeneity • A special case of C-M-H test; an approximate test (when n*=n12+n21>10) • Exact test (when n*=n12+n21<10)

  13. Level of Agreement: Kappa Coefficient • The larger the Kappa coefficient is; the stronger the agreement is • The difference between observed agreement and that expected under independence compared to the maximum possible difference is called Kappa coefficient

  14. SAS Output McNemar's Test Statistic (S) 17.3559 DF 1 Asymptotic Pr > S <.0001 Exact Pr >= S 3.716E-05 Simple Kappa Coefficient Kappa 0.6996 ASE 0.0180 95% Lower Conf Limit 0.6644 95% Upper Conf Limit 0.7348 Sample Size = 1600 Level of agreement

  15. Chi-square Test for Square Tables Consider a IxI table • Marginal homogeneity: • Symmetry: for all pairs of cells, Symmetry => marginal homogeneity <=

  16. Chi-square Test for Square Tables Ho: symmetry vs. Ha: not symmetry • Fitted values: • Standardized Pearson residuals: • Pearson Chi-square Test statistic: X^2 follows approximately Chi-square with df = I(I-1)/2

  17. Example: Coffee Purchase

  18. Example: Coffee Purchase • X^2 = 20.4 and df is 5(5-1)/2=10  lack of fit (reject Ho: symmetry)  which pairs of cells cause the lack of fit? Examine their standardized Pearson residuals  The pair (1,3) and (3,1) contribute the most; other pairs are fine (rij^2 is around 1 or less)

More Related