# Statistics for data Analysis and Regression

posted in: Research Paper | 0

Problem 1:

The data come from the American Time Use Survey. Each row represents a U.S. resident who was randomly sampled. People selected for the sample were called on a randomly chosen day and participated in an extensive interview designed to determine what they spent their time on in the previous 24 hours. Your data is a random sample of n=999 from this original data set (which was in the tens of thousands) and has only a special selection of variables.

Our interest in this problem is to understand what factors influence the amount of sleep we get each night, at least in terms of the few variables provided here that might address that issue

1) Perform a two-sample t-test to test whether or not the mean number of minutes of sleep differs on holidays compared to other days:

1. a) what is the value of the t-statistic?
2. b) what is the p-value?
3. c) State your conclusion in the context of the data. Use a significance level of 5%.

2) Fit a model that uses only the day of the week (day) to predict the number of minutes of sleep.

1. a) What is the mean number of minutes of sleep on Friday?
2. b) Interpret the estimate for daySunday.

3) Fit a full model using only age, eating, socializing, and homework to predict sleep.

Do not include categorical variables.

Comment on the model validity and support your comments with appropriate diagnostic plots. (Note we are not asking you to fix any problems you find; just note whether or not a problem exists.)

4) Do older people tend to sleep less, all other things being equal? Assume the model from question 3 is valid. State the value of the coefficient for age and provide the p-value and use these to answer the question. Use a 5% significance level.

5) Consider a transformation of the response variable and none of the predictor variables. Again, use only the age, eating, socializing, and homework variables as predictors.

1. a) What transformation does the inverse response plot suggest? Provide the plot and explain your answer.
1. b) What transformation does the Box-Cox transform suggest? Again, provide evidence based on your output.

6) Transform the sleep variable using the “rounded” power suggested by the box-cox method and fit the model using this transformed variable. Again, use only the age, eating, socializing, and homework variables as predictors.

In your opinion, did this improve the model? Explain in 1-2 sentences.

7) Is collinearity an issue with these predictors (untransformed)? Explain why or why not.

8) For the sake of simplicity, once again fit a model with untransformed response

variable. Use as predictors age, socializing, homework, day and holiday. (No interactions.) Perform best subsets regression. We will assume that all models are valid.

1. a) How many variables should be in the “best” model? Explain how you reached this decision.
1. b) State the BIC for your best model.
2. c) Which variables are in the best model?

9) Use your final model to predict the number of minutes of sleep on Sunday that is not a holiday, for John, who is average on all continuous variables in your model.

Your prediction should take the form of an interval at a 95% significance level.

Problem 2:

The following questions refer to data collected to examine the factors that drive auto insurance rates. (from National Highway Traffic Safety Administration). The data are at the state level: each observation is a state. The output you’ll need is provided

in a separate file analysis.pdf.

The variables are:

state: states in the U.S. plus Washington, D.C. num_drivers: number of drivers involved in fatal collisions per billion miles

perc_speeding: percentage of drivers involved in fatal collisions who were

speeding

perc_alcohol: percentage of drivers involved in fatal collisions who were alcohol-

impaired

perc_not_distracted: percentages of drivers involved in fatal collisions who were

not distracted.

perc_no_previous: percentage of drivers involved in fatal collisions who had not

been in previous accidents

insurance_premiums: car insurance costs per driver in dollars

losses: amount of money insurances companies paid for collissions per insured

driver.

1. Which of the following is the best interpretation of the slope for perc_speeding

(using the untransformed model)?

1. a) Controlling for the number of drivers involved in fatal collisions per billion miles,

states with an additional percentage point of drivers in fatal collisions who were

1. b) Controlling for all other variables in the model, states with an additional

percentage point of drivers in fatal collisions who were speeding pay, on average, an

1. c) Controlling for all other variables in the model, states with an additional

percentage point of drivers in fatal collisions are charged an additional premium of

\$0.81.

1. d) Controlling for the number of drivers involved in fatal collisions per billion miles,

states with an additional percentage point of drivers in fatal collisions who were

1. Suppose we examine a 95% confidence interval for the slope for perc_alcohol.

Which of the following is true?

1. a) The interval will contain 0.
2. b) The interval will not contain 0.
3. c) The interval will not contain 0 for 95% of all samples drawn from this population.
4. d) The interval will contain 0 for 95% of all samples drawn from this population.

1. Consider the F-test given in the summary output for the model. (Shown below,

but you can also find it in the output section.) Write the null and alternative

hypotheses that this F-statistic is testing:

F-statistic: 5.658 on 6 and 44 DF, p-value: 0.0002014

(a) Null Hypothesis:

(b) Alternative Hypothesis:

1. c) What do we conclude from this F-statistic based on the p-value? (Assume the

model is valid.)

1. The mean of losses is 134.49. The 95% confidence interval for the mean insurance

premium in states with losses of \$134.49 is (847, 926). If we calculate a 95%

confidence interval for any other amount of losses, the width of the new confidence

interval will be

1. a) wider
2. b) smaller
3. c) the same
4. d) it depends.

1. Here is out put from the box-cox power transform:

What does this output suggest? Choose the best answer:

1. a) It is best to not do a transformation.
2. b) None of the predictors are associated with the response variable.
3. c) It is best to do a log transform.
4. d) It is best to do some sort of a transformation