Section 40 MLR - Polynomial terms: lm outputs


40.1 Statistical Model

\[ \large y_{i} = \beta_0 + \beta_1 x_{1i} + \beta_2 x_{2i} + \beta_3 x_{2i}^2 + \epsilon_{i} \]

\[ \large fm \leftarrow lm(SBP \sim BMI + Age + I(Age \hat \space 2), \space data=BP) \]


\[ \large anova(fm) \]

Df Sum Sq Mean Sq F value Pr(>F)
BMI 1 15103.0386 15103.0386 2188.3255 0.0000
Age 1 335.4035 335.4035 48.5976 0.0000
I(Age^2) 1 23.5427 23.5427 3.4112 0.0654
Residuals 496 3423.2143 6.9016 NA NA
Total 499 18885.1991 NA NA NA


40.2 Estimates: Effects

\[ \large summary(fm) \]

Estimate Std. Error t value Pr(>|t|)
(Intercept) -441.6343 233.3528 -1.8926 0.0590
BMI 2.3322 0.0709 32.8882 0.0000
Age 18.3479 9.3452 1.9634 0.0502
I(Age^2) -0.1728 0.0935 -1.8469 0.0654


40.3 Estimates: Effects with centered BMI and Age

BP <- read.csv('data/BP.csv')

BP$cBMI <- scale(BP$BMI, center=mean(BP$BMI))
BP$cAge <- scale(BP$Age, center=mean(BP$Age))

fm <- lm(SBP ~ cBMI + cAge + I(cAge^2), data=BP)

\[ \large summary(fm) \]

Estimate Std. Error t value Pr(>|t|)
(Intercept) 102.1335 0.1443 707.6460 0.0000
cBMI 4.8743 0.1482 32.8882 0.0000
cAge 1.0025 0.1491 6.7221 0.0000
I(cAge^2) -0.1551 0.0840 -1.8469 0.0654


40.4 Plot

Note the curvilinear pattern due to Age for different values of BMI. As shown in the plot as well as from the model outcomes, the evidence is not strong (p>0.05). We will possibly remove the polynomial term from the final model. At this stage, however, we need to investigate the model further along with other predictors. The green dashed vertical lines shows the mean Age of the population. The mean BMI of the population is approximately 25.