By using the plot function in R, as well as the simple linear regression line function, we are able to get the following graph:
Cross-checking the simple linear regression line with our equation below, we can confirm that this is indeed correct.
The simple linear regression model seems appropriate for this situation as there is a single regressor, the sound pressure level, and a dependent variable, the blood pressure rise. We can see the relation that as the sound pressure level rises in decibels, the rise in blood pressure increases as well, in millimeters of mercury.
We can get the unbiased estimate σ2 by using the following formula:
\[σ^2=\frac{\Sigma (y-\hat{y})^2}{n-2}\]
With the help of table 1. above, the estimate of σ2 is: \[σ^2=\frac{31.27714}{20-2}=1.74\]
From the equation in table 1. above:
\[\hat{y}=-10.13+0.174x\]
we can plug in the value of x with 85 decibels to find the prediced mean rise in blood pressure for this specific value.
\[\hat{y}=-10.13+0.174(85)=4.66\]
At the sound pressure of 85 decibels, we can predict a 4.66 millimeter rise in blood pressure level.
##
## Call:
## lm(formula = UsefulRange ~ Brightness + Contrast, data = data)
##
## Residuals:
## Min 1Q Median 3Q Max
## -32.334 -20.090 -8.451 8.413 69.047
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 238.5569 45.2285 5.274 0.00188 **
## Brightness 0.3339 0.6763 0.494 0.63904
## Contrast -2.7167 0.6887 -3.945 0.00759 **
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Residual standard error: 36.35 on 6 degrees of freedom
## Multiple R-squared: 0.7557, Adjusted R-squared: 0.6742
## F-statistic: 9.278 on 2 and 6 DF, p-value: 0.01459
\[\hat{y} = b_0 + b_1 x_1 + b_2 x_2\] \[\hat{y} = 238.5569 + 0.3339 x_1 + (-2.7167) x_2\]
We can get the unbiased estimate σ2 by using the following formula:
\[σ^2=\frac{\Sigma e^2}{n-2}=\frac{SS_e}{n-p}\]
\[SS_e=\Sigma (y-\hat{y})^2\]
Pulling these values from the function above, we get:
## [1] 1321.273
The unbiased estimator, σ2, is 1,321.273.
From the summary above, we can get the following standard errors of the regression coefficients:
\[Brightness = 0.6763\] \[Contrast = 0.6887\]
From the equation above, we can get the predicted useful range when brightness = 80 and contrast = 75: \[\hat{y} = 238.5569 + 0.3339 x_1 + (-2.7167) x_2\] Plugging in these values: \[\hat{y} = 238.5569 + 0.3339 x 80 + (-2.7167) x 75 = 61.5164\] The predicted useful range will be 61.5164.
From the p-value in the summary above, 0.01459 and comparing it to α = 0.05: \[0.01459 < 0.05\] Therefore, the regression is significant.
We can get the t-value from the following equation:
\[t_\hat{β}=\frac{\hat{β} - β_0}{SE(\hat{β})}\]
However, since the t-value was already provided from the summary above, we can get the following:
\[β_{1} - Brightness\]
\[H_0: β_1 = 0\]
\[H_1: β_1 > 0\]
\[t_1=0.494\]
Using the pt function, we get a p-value of:
## [1] 0.6827085
A p-value of 0.6827085 which is greater than 0.05, thus we Fail to Reject the Null Hypothesis and there is no relationship with the model.
\[β_{2} - Contrast\]
\[H_0: β_2 = 0\] \[H_1: β_2 > 0\]
\[t_2=-3.945\] Using the pt function, we get a p-value of:
## [1] 0.002132922
A p-value of 0.002132922 is less than 0.05, thus we Accept the Alternative Hypothesis and there is a strong relationship with the model.