# Three groups comparison - Repeated measurements

#### twentyseven

##### New Member
Hello everyone

A knee prosthesis is well positioned when the line that goes from the center of the hip to the center of the ankle passes through the middle of the knee (more or less). We have three methods of knee alignment (conventional, navigation or robotic surgery). And we measured the alignment before and after surgery in the x-rays.
So we have the following variables:
• axis_0: Preoperative alignment.
• axis_1: Postoperative alignment.
• error_0: Difference (in absolute value) between the optimum (180 degrees) and the preoperative alignment. [error_0 = abs(180 - axis_0)]
• error_1: Difference (in absolute value) between the optimum (180 degrees) and the postoperative alignment. [error_1 = abs(180 - axis_1)]
• error_change: Difference between the postoperative and preoperative error. That is, what has improved the alignment of the knee. [error_change = error_1 – error_0]
We would like to see what method is better to get a better alignment. The trick here is that the postoperative alignment is the main indicator for a good result, but obviously is not the same to start from 179 degrees than from 160.

So we tried several options:

ANALYSIS OPTION 1: LINEAR REGRESSION
Code:
. reg error_change i.group, baselevels

Source |       SS           df       MS      Number of obs   =       124
-------------+----------------------------------   F(2, 121)       =      4.03
Model |  169.390993         2  84.6954966   Prob > F        =    0.0202
Residual |  2542.25035       121  21.0103334   R-squared       =    0.0625
Total |  2711.64134       123  22.0458645   Root MSE        =    4.5837

-------------------------------------------------------------------------------
error_change |      Coef.   Std. Err.      t    P>|t|     [95% Conf. Interval]
--------------+----------------------------------------------------------------
group |
Conventional  |          0  (base)
Navigated  |   .3461958   1.046932     0.33   0.741    -1.726483    2.418875
Robotic  |  -2.208407   1.015209    -2.18   0.032     -4.21828   -.1985336
|
_cons |  -3.886806   .7639505    -5.09   0.000    -5.399247   -2.374364
-------------------------------------------------------------------------------

. pwcompare group, effects

Pairwise comparisons of marginal linear predictions

Margins      : asbalanced

--------------------------------------------------------------------------------------------
|   Contrast   Std. Err.      t    P>|t|     [95% Conf. Interval]
---------------------------+----------------------------------------------------------------
group |
Navigated vs Conventional  |   .3461958   1.046932     0.33   0.741    -1.726483    2.418875
Robotic vs Conventional  |  -2.208407   1.015209    -2.18   0.032     -4.21828   -.1985336
Robotic vs Navigated  |  -2.554603   .9795282    -2.61   0.010    -4.493837   -.6153684
--------------------------------------------------------------------------------------------
ANALYSIS OPTION 2: REPEATED MEASURES ANOVA
Code:
. anova error_ group / id|group pre_or_post group#pre_or_post, repeat(pre_or_post)

Number of obs =        248    R-squared     =  0.7094
Root MSE      =    3.24117    Adj R-squared =  0.4069

Source | Partial SS         df         MS        F    Prob>F
------------------+----------------------------------------------------
Model |  3103.7283        126   24.632764      2.34  0.0000
|
group |  48.500335          2   24.250168      1.77  0.1739
id|group |   1653.248        121   13.663206
------------------+----------------------------------------------------
pre_or_post |  1244.8936          1   1244.8936    118.50  0.0000
group#pre_or_post |  84.695502          2   42.347751      4.03  0.0202
|
Residual |  1271.1252        121   10.505167
------------------+----------------------------------------------------
Total |  4374.8535        247   17.711957

Between-subjects error term:  id|group
Levels:  124       (121 df)
Lowest b.s.e. variable:  id
Covariance pooled over:  group     (for repeated variable)

Repeated variable: pre_or_post
Huynh-Feldt epsilon        =  1.0167
*Huynh-Feldt epsilon reset to 1.0000
Greenhouse-Geisser epsilon =  1.0000
Box's conservative epsilon =  1.0000

------------ Prob > F ------------
Source |     df      F    Regular    H-F      G-G      Box
------------------+----------------------------------------------------
pre_or_post |      1   118.50   0.0000   0.0000   0.0000   0.0000
group#pre_or_post |      2     4.03   0.0202   0.0202   0.0202   0.0202
Residual |    121
-----------------------------------------------------------------------

. pwmean error_, over(group) mcompare(tukey) effects

Pairwise comparisons of means with equal variances

over         : group

---------------------------
|    Number of
|  Comparisons
-------------+-------------
group |            3
---------------------------

--------------------------------------------------------------------------------------------
|                              Tukey                Tukey
error_ |   Contrast   Std. Err.      t    P>|t|     [95% Conf. Interval]
---------------------------+----------------------------------------------------------------
group |
Navigated vs Conventional  |  -.4334943   .6786801    -0.64   0.799    -2.033854    1.166866
Robotic vs Conventional  |    .610294    .658115     0.93   0.624    -.9415724     2.16216
Robotic vs Navigated  |   1.043788   .6349849     1.64   0.229    -.4535363    2.541113
--------------------------------------------------------------------------------------------
What is the correct p-value here? 0.0202 as in the first analysis? But why do I get non significant differences in the post hoc analysis?

ANALYSIS OPTION 3: GENERAL LINEAR REPEATED MEASURES MODEL (SPSS)

I am not familiar with SPSS... I don't know if I should use between subjects contrast (p=0,020) or inter-subjects contrast (p=0.174). Post hoc comparisons are not significative (as in the option 2) so I guess that I should use p=0.174... but the graphical representation suggest otherwise.
ç
Thanks a lot for your help.