Image by AuthorThe Jonckheere-Terpstra test is a nonparametric statistical test that detects ordered trends across three or more independent groups. While similar tests like the Kruskal-Wallis test check whether any differences exist between groups, the Jonckheere-Terpstra test examines whether groups follow a directional pattern, such as consistently increasing or decreasing values.
This test is well-suited when your groups have a logical order and you expect the outcome variable to follow that same order. For instance, if you’re testing different drug dosages, you might expect that higher doses produce stronger effects in a predictable direction.
When to Use the Jonckheere-Terpstra Test
Consider the Jonckheere-Terpstra test when your research meets these criteria:
Data Structure: You have three or more independent groups with a natural ordering, such as low–medium–high treatment levels, increasing time periods, or progressive severity categories.
Variable Types: Your independent variable is ordinal (has meaningful order), and your dependent variable is continuous or ordinal.
Hypothesis: You expect a directional trend rather than just any difference between groups. For example, you predict median values will increase as group levels increase.
Distribution: Your data doesn’t meet the assumptions for parametric tests like ANOVA, especially the normality assumption.
Additionally, observations should be independent across and within groups, and the alternative of interest should be monotonic (consistently increasing or decreasing across the ordered groups).
How the Test Works
The Jonckheere-Terpstra test uses a rank-based approach that makes it resistant to outliers and non-normal distributions.
First, all observations from all groups are combined and ranked from smallest to largest. This ranking process transforms the original values into positions, making the test relatively insensitive to the specific distribution of your data.
Next, the test examines whether these ranks tend to increase (or decrease) systematically as you move from the first group through the last group. It does this by comparing each observation with observations in higher-ordered groups and counting how many times the expected order is maintained (so-called “favorable” pairs).
The test produces a statistic (often denoted as J) based on the count of favorable pairs, which is then standardized to a Z statistic under large-sample conditions. The standardized statistic is converted to a p-value, indicating the probability of observing such a strong trend by chance alone if no real trend exists in the population.
Practical Example
A pharmaceutical researcher is testing a new anxiety medication at three dosage levels: 0 mg (placebo), 10 mg, and 20 mg. Twenty patients are randomly assigned to each group, and anxiety levels are measured on a scale from 0 to 100 after treatment.
The researcher’s hypothesis is clear: anxiety scores should decrease as dosage increases. In other words, the median anxiety score for the 0 mg group should be greater than the 10 mg group, which should be greater than the 20 mg group.
After administering treatments and collecting data, the median anxiety scores are 72 for the 0 mg group, 58 for the 10 mg group, and 45 for the 20 mg group. These medians show the expected pattern, but the Jonckheere-Terpstra test determines whether this pattern is statistically significant or could have occurred by chance.
The test ranks all 60 anxiety scores together, then examines whether patients in higher-dose groups tend to have lower ranks (indicating lower anxiety). If the test produces a small p-value (less than 0.05), the researcher can conclude that there’s a statistically significant decreasing trend in anxiety as dosage increases.
Advantages Over Alternative Tests
The Jonckheere-Terpstra test has advantages in specific scenarios. Unlike the Kruskal-Wallis test, which detects any differences between groups but doesn’t test for specific patterns, the Jonckheere-Terpstra test focuses on detecting ordered trends. This focused approach can be more powerful when you have a directional hypothesis.
Compared to parametric alternatives like linear regression or trend analysis, the Jonckheere-Terpstra test requires no assumptions about the distribution of your data or the equal spacing of your ordered groups. This makes it useful when drug doses, severity levels, or time points aren’t evenly spaced or when outcome distributions are skewed.
Common Applications
The test appears frequently in several research areas:
Medical Research: Testing whether patient outcomes improve with increasing treatment intensity or evaluating dose–response relationships in clinical trials.
Toxicology: Examining whether toxic effects increase with higher concentrations of a substance.
Psychology: Assessing whether behavioral responses change systematically with increasing stimulus intensity or exposure duration.
Education: Evaluating whether student performance increases across progressive difficulty levels or sequential instruction methods.
Interpreting Results
When you get results from a Jonckheere-Terpstra test, focus on two key elements. The p-value indicates whether the observed trend is statistically significant. A small p-value (below your chosen significance level) suggests the ordered pattern in your data is unlikely to have occurred by chance.
The direction of the trend should match your hypothesis. The test can detect either increasing or decreasing trends, so verify that the pattern in your sample medians or means aligns with your predicted direction. In practice, researchers often specify a one-sided alternative (e.g., “increasing across groups”) to match the hypothesized direction; if you do not have a clear directional expectation, use a two-sided test.
Conclusion
The Jonckheere-Terpstra test works well when you have ordered groups and expect a directional trend in your outcome variable. By focusing on ordered alternatives rather than any difference between groups, it provides better sensitivity for detecting patterns in dose–response studies, progressive treatment evaluations, and similar research designs. When your research question involves a directional hypothesis across ordered groups, this test is often more appropriate than general nonparametric tests.
