What type of statistical test would you use to examine the difference in these tests to see if there is a difference between the before and after sample?

Treatment A results Grade 8 Grade 9 Grade 10 Grade 11 Grade 12
Before Treatment Count (week0) 0 11 33 34 22
After Treatment Count (week12) 4 18 35 26 17

Thanks ahead of time! I'm having trouble wrapping my head around this one for some reason...


A $2 \times 5$ contingency (multiway) table analysis, based on a chi-squared test. It's essentially a test of proportions of the frequencies (count data) to determine if anything "tracks" between the two factors, before/after and grade. Contingency table analysis can be complex, however, wherein different hypotheses can be employed surrounding questions about independence, correlation, trends, patterns.

Since you do have before and after data, where subjects are their own controls, there may be within-subject correlation issues that need to be taken into account. In other words, there can be some predictability between the before and after data, since the frequencies in the after data are not independent of the frequencies in the before data, because they are correlated.

If your before and after categories were drug vs. placebo, and different subjects were evaluated for grade in these two categories, then the frequencies would be independent. For $2 \times 2$ tables with before and after vs. e.g. disease/no disease, or low grade vs high grade, look at the McNemar test. Otherwise, the analysis may be attacked from a longitudinal data analysis perspective.

  • $\begingroup$ If I had the data for every subject (e.g. Subject 1 was Grade9 before and is now Grade10 for all 100 subjects) how would you approach this? I organized the data in this table because I thought it would be easiest to visualize (with corresponding 2 bar graphs), but I do have the data for all 100 subjects. $\endgroup$ – Sameer Apr 11 at 20:07
  • $\begingroup$ Then you would have other cells that have zeroes in them, and in contingency table analysis it is not recommended to have any cells with <5. Look at the Yates correction for continuity. Also, it's common to "collapse" tables when cells become sparse; you can do whatever you want with grade. That is, make 3 columns for low, medium, and high grade by collapsing columns together (adding counts together), or make 2 columns with low,high grade. These are called clinical decisions, based on medical/disease/pathology knowledge. This is done all the time. $\endgroup$ – wrstks Apr 11 at 20:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.