2

I need to perform a Jonckheere-Terpstra test, but I am not sure how to do it and how to interpret the results.

I have following data: Three groups doctors1, doctors2, doctors3 And how often they ask their patients about their emotional state (0 never - 4 always).

I predict such order doctors1 < doctors2 < doctors3

In SPSS I chose the non-parametric tests JT and than-"from smallest to largest" (groups 1-2-3) and pairwise comparison. My results are p value 0.077 (two-sided)

My questions are: I dont really understand what exactly "from smallest to largest" means. Does it mean just 1-2-3 order of the groups or is it my hypothesis, that the first group has the smallest value?

Second question is - should I divide p value by two? I have a directional hypothesis... if i do it, than i would get statistical sign results. I am really confused.

ttnphns
  • 51,648
  • 40
  • 253
  • 462
Katja
  • 23
  • 4
  • I think i found an answer on my first question: https://www.ibm.com/support/knowledgecenter/en/SSLVMB_subs/statistics_mainhelp_ddita/components/nonparametric_tests/idh_idd_npar_independent_settings_tests.html But what with the second question? Do i need to divide the p value by two? – Katja May 25 '18 at 11:18
  • Possible duplicate of [Jonckheere-Terpstra interpretation](https://stats.stackexchange.com/questions/36184/jonckheere-terpstra-interpretation) – mdewey May 25 '18 at 13:14
  • @mdewey No, that is not a duplicate. Here is a specific question, related, but not the same. – ttnphns May 25 '18 at 13:21

1 Answers1

1

Jonckheere-Terpstra test is appropriate for ordered samples only. If your three groups of doctors are knowingly ordered upon some characteristic which may be important in treating their patient's emotional state - then you may use the test. For example, group1 could be students, group2 interns and group3 experienced doctors. You might expect that group3>group2>group1 in skills in treatment of psychiatric patients. But if you can't order your groups of doctors meaningfully before the statistical test - don't use Jonckheere-Terpstra, use Kruskal-Wallis instead.

I recommend you to read Jonckheere-Terpstra interpretation with a number of good answers related to your question.

In the present answer I want to focus on the interpretation of p-value of the test. What statistical hypotheses does the singificance pertain to?

According to SPSS Statistics Algorithms document, Jonckheere-Terpstra outputs 2-sided sig. $p$$^1$. This is significance of the two sided test (let S1, S2,...,Sk denote the location parameters of the corresponding ordered samples which codes ascend like 1, 2,...,k):

H0: S1=S2=...Sk vs H1: {S1<=S2<=...Sk with at least one strict inequality (<) or S1>=S2>=...Sk with at least one strict inequality (>)}.

So the alternative hypothesis H1 of this test is double. If you take in consideration the sign of the standardized test statistic T you can say in favour of which part of H1 the null is being rejected; namely in favour of the S1<=S2<=...Sk - when T>0, or in favour of the S1>=S2>=...Sk - if T<0. Consequently, $p/2$ is one-sided significance for case "T>0 and H1: S1<=S2<=...Sk", as well as for case T<0 and H1: S1>=S2>=...Sk".

In full (for any sign of T) the two one-sided tests are formulated as:

H0: S1=S2=...Sk vs H1asc: S1<=S2<=...Sk with at least one strict inequality (<). The one-sided p-value of it is: $p/2$, if T>0, and $1-p/2$ otherwise.

H0: S1=S2=...Sk vs H1desc: S1>=S2>=...Sk with at least one strict inequality (>). The one-sided p-value of it is: $p/2$, if T<0, and $1-p/2$ otherwise.

When you request Jonckheere-Terpstra in SPSS, it wants you to specify "Hypothesis order": largest to smallest or smallest to largest. You will notice that whichever you choose does not influence the output two-sided $p$ (and the value or sign of T). The specification is important not for the omnibus result but for the post-hoc multiple comparisons of the samples (if you request to do it after the omnibus test). The omnibus significance that the multiple comparisons will be based on is the significance of the described above one-sided test: smallest to largest corresponds to H1asc while largest to smallest to H1desc.


$^1$ Which is, by the way, equal to the significance of Kendall' tau-b correlation between those dependent and independent variables.


Example.

   group response

       1      1.0
       1      1.0
       1      1.0
       1      1.0
       1      1.0
       1      2.0
       1      2.0
       1      2.0
       1      2.0
       1      3.0
       1      3.0
       2      1.0
       2      1.0
       2      1.0
       2      1.0
       2      2.0
       2      2.0
       2      2.0
       2      2.0
       2      2.0
       2      3.0
       3      1.0
       3      1.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      2.0
       3      3.0
       3      3.0
       3      3.0
       3      3.0
       3      3.0
       3      3.0
       3      3.0
       3      3.0

Like Kruskal-Wallis, Jonckheere-Terpstra compares stochastic dominance (not means or medians) or nonparametric locations, and the most appropriate statistic to display now for the 3 groups would be Hodges-Lehmann pseudomedian. I'm showing, however, mean and median, because they still relate the fact that the 3rd group is the highest response while the 1st and the second are similar:

enter image description here

Request Jonckheere-Terpstra test with "Hypothesis order": smallest to largest (ascending):

NPTESTS 
  /INDEPENDENT TEST (response) GROUP (group) JONCKHEERE_TERPSTRA(ORDER=ASCENDING COMPARE=PAIRWISE) 
  /MISSING SCOPE=ANALYSIS USERMISSING=EXCLUDE
  /CRITERIA ALPHA=0.05  CILEVEL=95.

enter image description here

The 2-sided $p=.016$ is significant. If you want a one-sided, directed alternative hypothesis, which one is it? If it is ascending, S1<=S2<=...Sk one, then its p-value is $p/2=.008$ because the standardized statistic T is positive. If it is descending, S1>=S2>=...Sk one, its p-value is $1-.008$.

Pairwise multiple comparisons (based on Mann-Whitney U):

enter image description here

reveal significant differences group3>group2 and group3>group1 (though Bonferroni-corrected remains only the first difference).

If you requested "Hypothesis order": largest to smallest you'd have every statistic the same, yet there would be no significant post-hoc differences:

enter image description here

which is understandable since the omnibus test significance for the descending-order one-sided alternative is $1-.008$, as mentioned.

ttnphns
  • 51,648
  • 40
  • 253
  • 462
  • Thank you so much for your answer. Somehow i still dont get it. Here are my data: Mdn1 ≥ Mdn2 ≥ Mdn3 (largest to smallest) The J-T test revealed significant results (TJT = 510.00, z = 4.85, p < .00) indicating that medians of the groups are following a decreasing trend. So far so good. Second hypothesis: Mdn1 ≤ Mdn2 ≤ Mdn3 (smallest to largest) The J-T test was significant (TJT = 538.50, z = 5.59, p < .00). But z statistic is >0. It should be <0. Does it mean, that my hypothesis is not true? The descriptive data are consistent with the hypothesis Mdn1 ≤ Mdn2 ≤ Mdn3 – Katja May 26 '18 at 10:55
  • I don't get what yiu are saying. The value and sign of the test statistic and the (2-sided) p-value of the omnibus (J-T) test does not depend on the "hypothesis order" you specify; that order is important for p-values of post-hoc multuple comparisons. – ttnphns May 26 '18 at 12:12
  • Also to mention, neither J-T nor Kruskal-Wallis tests are not the tests of medians, they are tests of stochastic dominance. – ttnphns May 26 '18 at 12:14
  • You could post your data (for us to check your results) if you still have difficulties. – ttnphns May 26 '18 at 12:29
  • Thank you again! My data are: three groups. 1-2-3 I run the test now differently: non-parametric tests, legacy dialogs, k independent samples-grouping variable 1:3 The results: 1) TJT = 72.00, z = -4.85, p < .00, H1 that is confirmed: 1>2>3 2) TJT = 538.50, z = 5.59, p < .00, H1 that is confirmed: 1<2<3 3) TJT = 363.50, z = 1.77, p = .077 two-tailed or significant when directional hypothesis: p<0.05 one-tailed. H1 that is confirmed: 1<2<3 did i get it right? – Katja May 26 '18 at 13:39
  • H3: here i had a -priori hypothesis, that the third group would have the highest values. Thats why i want to take p/2. But i am not sure, if i can do so – Katja May 26 '18 at 13:52
  • You better post some data in your question, not only the results. – ttnphns May 26 '18 at 19:28
  • done. these are the data for the directional hypothesis 3: Group 1< Gr 2< Gr 3. And i want to take the p/2, cause I had an a-priori directional hypothesis – Katja May 27 '18 at 07:19
  • Katja please see/use my example and edits. – ttnphns May 27 '18 at 16:30
  • Thank you so much for your answer!!! But I really don´t understand, why I get completely other results. My results in SPSS are: 3) TJT = 363.50, z = 1.77, p = .077. Did you use another program? Or do I do something wrong? If you use another program (e.g. R), how can it be, that the results are so different? – Katja May 27 '18 at 18:54
  • If you use the data and the syntax _that_ I posted in the _answer_ you must get my result. Did you? I used SPSS 22. – ttnphns May 27 '18 at 19:21
  • No, i got my results. I compared the data and the data in your answer are a little bit different (some values are mixed up). That would explain the difference. But now I finally get it :) – Katja May 28 '18 at 13:45
  • Yes, I changed your data a bit making up mine. I did it on purpose for some reason. – ttnphns May 28 '18 at 18:00
  • sure sure, no problem. Also better for me such way. :) Thank you again, no questions are left. – Katja May 29 '18 at 12:52