Age and Price data for a sample of 12 cars
Age (years) 5 4 5 5 7 6 6 2 7 7 8 9
Price(Hundreds) 95 100 75 82 89 98 66 95 179 72 49 84
At the 1% significance level do the data provides sufficient evidence to conclude that age and price of cars are negatively correlated. a) Perform a hypothesis test ( 6 points)
(For computing correlation, I have used R code:
x=c(5,4,5,5,7,6,6,2,7,7,8,9)
y=c(95,100,75,82,89,98,66,95,179,72,49,84)
#x=Age, y=Price
round(cor(x,y),4)
)
For finding regression equation I have used R code:
x=c(5,4,5,5,7,6,6,2,7,7,8,9)
y=c(95,100,75,82,89,98,66,95,179,72,49,84)
#x=Age, y=Price
m=lm(y~x)
round(m$coefficients,4)
m1=lm(x~y)
round(m1$coefficients,4)
Get Answers For Free
Most questions answered within 1 hours.