Continuing with the Drug.jmp sample data table, this example fits a model where the slope for the covariate depends on the level of Drug. After fitting the model, the example compares the least square means for the levels of Drug at a specific value of the covariate x.
1.
|
2.
|
Select Analyze > Fit Model.
|
3.
|
4.
|
This adds terms up to the degree specified in the Degree box to the model. The default value for Degree is 2. Thus the main effects of Drug and x, and their interaction, Drug*x, are added to the model effects list.
5.
|
Click Run.
|
This specification adds two columns to the linear model (call them x4i and x5i) that allow the slopes for the covariate to differ by Drug level. The new variables are formed by multiplying the indicator variables for Drug by the covariate values, giving the following formula:
Table 3.1, shows the coding for this model. The mean of X, which is 10.7333, is used in centering continuous terms.
X1
|
||
X2
|
||
X3
|
||
X4
|
X – 10.7333 if a, 0 if d, –(X – 10.7333) if f
|
|
X5
|
A portion of the report is shown in Figure 3.6. The Regression Plot shows fitted lines with different slopes. The Effect Tests report gives a p-value for the interaction of 0.56. This is not significant, indicating the model does not need to include different slopes.
Figure 3.6 Plot with Interaction
You now want to compare the least square means for the levels of Drug at a specific value of the covariate x. This type of comparison in an analysis of covariance model is sometimes referred to as spotlight analysis. For more information about spotlight analysis, see Spiller et al. (2013).
1.
|
From the red triangle menu next to Response y, select Estimates > Multiple Comparisons.
|
2.
|
In the Multiple Comparisons window, select User-Defined Estimates.
|
3.
|
Select all three values below Choose Drug Levels.
|
5.
|
Click Add Estimates.
|
6.
|
Click OK.
|
The User-Defined Estimates report shows least square means estimates for each level of Drug with the covariate x set to 12.5. The red triangle menu next to Multiple Comparisons for User-Defined Estimates contains options that enable you to test for differences among the estimates.
Figure 3.7 User-Defined Estimates Report
7.
|
From the red triangle menu next to Multiple Comparisons for User-Defined Estimates, select Comparisons with Overall Average.
|