Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1.For the data below: X Y 5 10 3 6 6 7 4 3 2 4 Compute the Pearson correlation.

ID: 2906616 • Letter: 1

Question

1.For the data below:

                 X      Y

               5     10

               3       6

               6       7

               4       3

               2       4

Compute the Pearson correlation.

Find the regression equation for predicting Y from X.

          c. Calculate the predicted Y for each X value, find each residual (Y – ?), square each

               residual and add the squared values to obtain SSresidual.

          d. Does the regression equation predict a significant portion of the variability for the Y

               scores?

2.A researcher is interested consumer preferences among three brands of yogurt. A sample of 90 people is obtained and each individual is asked to taste each brand and then select his/her favorite. The resulting frequency data are as follows:

                             Brand A     Brand B     Brand C

      37

      21

      32

          Do the data indicate any significant preferences among the three brands? Test at the .05 level of significance.    

3.An insurance investigator has observed the people with some astrological signs tend to be safer drivers the people with other signs. Using insurance records, the investigator classified 200 people according to their astrological signs and whether or not they were involved in a car accident during the previous 12 months. The data are as follows:

    Accident

         7

          4

        19

    No Accident

        73

         46

        51

Do the data indicate a significant relationship between sign and accidents? Test at the .05 level of significance.

      37

      21

      32

Explanation / Answer

Q1)

compute the correlation coefficient:

x = c(5,3,6,4,2)
y = c(10,6,7,3,4)
a) r = cor(y,x) =  0.5773503

b) y =  2.0000+ 1.0000 *x

c) y.hat = predict(lm(y~x))

y= 1 2 3 4 5
yhat 7 5 8 6 4

error = y-y.hat

SSError = sum((y-y.hat)^2)

SSresidual = 20

d)

summary(model)

Call:

lm(formula = y ~ x)

Residuals:

1 2 3 4 5

3.00e+00 1.00e+00 -1.00e+00 -3.00e+00 1.11e-16

Coefficients:

Estimate Std. Error t value Pr(>|t|)

(Intercept) 2.0000 3.4641 0.577 0.604

x 1.0000 0.8165 1.225 0.308

Residual standard error: 2.582 on 3 degrees of freedom

Multiple R-squared: 0.3333, Adjusted R-squared: 0.1111

F-statistic: 1.5 on 1 and 3 DF, p-value: 0.3081

there is no significant variability on y by using x with the help of adjusted r square and p-value approach.

Q2)

x = c(37,21,32)
chisq.test(x)

Chi-squared test for given probabilities

data: x
X-squared = 4.4667, df = 2, p-value = 0.1072

p values implies that there is no significant among three brands(assume equal preferences=1/3)

Q3)

Accident =c(7,4,19)
No.Accident = c(73,46,51)
tb= rbind(Accident,No.Accident)
chisq.test(tb)

Pearson's Chi-squared test

data: tb
X-squared = 12.468, df = 2, p-value = 0.001962

there is significant relationship between sign and accidents.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Chat Now And Get Quote