Name: Question 8.. ...15 points Use simple linear regression. A type of concrete
ID: 2948258 • Letter: N
Question
Name: Question 8.. ...15 points Use simple linear regression. A type of concrete is tested for yaxial strength in MPa and x cube strength in MPa. The sample data is: x 112.3 91.0 92.7 86.0 102.0 99.2 95.8 103.5 89.0 86.7 y75.0 710 57.7 48.7 74.3 73.3 68.0 59.3 578 485 points) (a) Obtain the equation of the least squares line, and interpret its slope Name: nts) (b) Calculate and interpret the coefficient of determination. Name: (c) Provide the expression for the sample correlation coefficient provide the possible maxi- mum and minimum value it can have.Explanation / Answer
> y <- c(75.0, 71.0 , 57.7 , 48.7 , 74.3, 73.3, 68.0 , 59.3 , 57.8 , 48.5);y
[1] 75.0 71.0 57.7 48.7 74.3 73.3 68.0 59.3 57.8
[10] 48.5
> x <- c(112.3, 91.0 , 92.7 , 86.0 , 102.0 , 99.2 , 95.8 , 103.5 , 89.0 , 86.7);x
[1] 112.3 91.0 92.7 86.0 102.0 99.2 95.8
[8] 103.5 89.0 86.7
> length(y); length(x)
[1] 10
[1] 10
> dat <- data.frame(y,x);dat
y x
1 75.0 112.3
2 71.0 91.0
3 57.7 92.7
4 48.7 86.0
5 74.3 102.0
6 73.3 99.2
7 68.0 95.8
8 59.3 103.5
9 57.8 89.0
10 48.5 86.7
a )
> regression <- lm(y ~ x ,data = dat);regression
Call:
lm(formula = y ~ x, data = dat)
Coefficients:
(Intercept) x
-20.577 0.876
b)
> summary(regression)
Call:
lm(formula = y ~ x, data = dat)
Residuals:
Min 1Q Median 3Q Max
-10.788 -5.275 -1.191 5.309 11.862
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) -20.5772 28.7899 -0.715 0.4951
x 0.8760 0.2994 2.926 0.0191
(Intercept)
x *
---
Signif. codes:
0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Residual standard error: 7.57 on 8 degrees of freedom
Multiple R-squared: 0.5169, Adjusted R-squared: 0.4565
F-statistic: 8.559 on 1 and 8 DF, p-value: 0.01913
coefficient of determination is 0.5169
c)
sample correlation coefficient is denoted by r
> r <- cor(y,x);r
[1] 0.7189507
maximum possible value of r is +1 and minimum possible value of r is -1
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.