# Observed versus Expected Slope Comparison

#### CrystalH

##### New Member
Hello,

I am performing an analysis (for dissertation project) where I am comparing the sum of branch lengths from phylogenetic trees reconstructed from altered datasets (Group 0) versus sum of branch lengths from phylogenetic trees reconstructed from control datasets (Group 1). Then I am considering the observed values (the actual branch lengths from each tree) versus the expected values (the branch lengths from the control trees). The data is below:

Group Observed Expected

.00 1.50 3.01
.00 3.58 9.98
.00 1.00 4.00
.00 3.03 7.61
.00 2.52 6.41
.00 .91 3.13
.00 2.74 4.10
.00 1.89 4.44
.00 1.79 3.42
.00 2.11 3.74
.00 .52 1.60
1.00 3.01 3.01
1.00 9.98 9.98
1.00 4.00 4.00
1.00 7.61 7.61
1.00 6.41 6.41
1.00 3.13 3.13
1.00 4.10 4.10
1.00 4.44 4.44
1.00 3.42 3.42
1.00 3.74 3.74
1.00 1.60 1.60

After finding the regression lines for each group, I get two lines...for the control group, y = 1x, as expected since the values were plotted against each other, and the expectation is that of no change from the control tree group. For the altered group, y = 0.343x + 0.356. To find out if the slopes are statistically significantly different, I used SPSS (Analyze -> General Linear Model ->Univariate) to identify whether or not there was an interaction between the covariate (expectation) and the IV (group). The interaction term is statistically significant (p < 0.0005), indicating a violation of homogeneity of regression slopes.

My question is, by doing this analysis, am I able to report that the slopes are statistically significantly different? I think that lack of homogeneity between regression slopes is the same as them being statistically significantly different, but I wanted to run it across the forum to make sure I am correct.

Thank you.

#### hlsmith

##### Less is more. Stay pure. Stay poor.
Since these data seem matched you may want to just find the mean of the differencs and run a Wilcoxon ranked sum test on that parameter. Not sure you are addressing the paired nature and gaining much from your listed procedures if they are 11 different pairs (what are you graphing). Perhaps you are fine, but the terms observed and expected typically have a certain statistical definition and I am not thinking you are using them. I got the vibe from this description, observed means experimental group and expected represented the control group.

As for your question, a significant interaction term means the slopes are not congruent and that the variable stratefied by, poses potential source of effect modification.

#### fed1

##### TS Contributor
I think you are making a bit of an unneccessary complication here. since the slope in group 1 is obviously going to be 1, just fit an single, simple linear regression in group 0, and test if slope is 0.

This is equivalent to testing whether observed and expected are correlated, and hence the 'paired nature' of the data has been allowed for.