Least squares in each group

If two numerical variables, X and Y, are recorded from each of several groups of individuals (or equivalently, if we have two numerical variables, X and Y, and a categorical variable, Z, that can be used to split the individuals into groups), we can separately examine the relationship between X and Y in each group.

If the relationship between X and Y is different in the different groups, this should lead to more accurate predictions of Y from X.

Body fat of AIS athletes

The scatterplot below again shows the relationship between Body fat and Body mass index (BMI) for the AIS athletes. The least squares line (and the equation under the scatterplot) could be used to predict Body fat from BMI.

We saw on the previous page that the relationship between Body fat and BMI is different for males and females. It would therefore be better to separately study and model the relationships for the two sexes.

Select Separate lines from the pop-up menu. Separate least squares lines are shown for the males and females.

Using the separate LS lines for males and females should allow us to predict Body fat from BMI more accurately.