Answered You can hire a professional tutor to get the answer.

QUESTION

USING R and RStudio Must download this .txt file: https://ufile.io/pi6r7 Lab 3: Model Building Download the data file "TRUCKING.txt" from Canvas....

USING R and RStudio

Must download this .txt file: https://ufile.io/pi6r7

Lab 3: Model Building Download the data file "TRUCKING.txt" from Canvas. PROBLEM. The research problem is to model the price charged for trucking service in Florida. In the early 1980s, several states removed regulatory constraints on the rate charged for intrastate trucking services, Florida being the first one to embark on a deregulation policy. The objective of the regression analysis is twofold: (1) assess the impact of deregulation on the prices charged for trucking service in Florida, and (2) estimate a model of supply price fore predicting future prices. DATA. The data (n = 134) were obtained from a particular carrier whose trucks originated from either the city of Jacksonville or Miami. The dependent variable of interest is the price in dollars charged per ton-mile. The potential predictors are: Use the following prompts to build your model. Note: (1) The suggested R commands are not necessarily the complete command for you to just copy and paste. It's just a hint. Use the help file to find out how to call these functions in the correct way. Import data from the .txt file into R. Try read.table() or use the drop-down menu. If using read.table(), remember to add the argument header=TRUE to override the default. Use dim() to check the number of rows in the dataset is equal to the correct sample size.

1. Use head() and str() to learn about the types and codings of the variables. Have all categorical variables been read in correctly as the "factor" type?

2. Use cor() and pairs() to check the marginal relation among the quantitative variables. What do you see?

3. Fit the initial "full" model. What is your full model?

4. Use vif() to check multicollinearity in the initial "full" model. Do the VIF values suggest you remove some of the predictors? Are these findings consistent with your findings from question 3?

5. Refit a new model after removing predictor(s) as suggested above. Use residualPlots() to check the residual distribution of the fitted model. What do you see? Does a transformation seem to be needed?

6. If deemed necessary, conduct a transformation and refit the model. Which transformation did you choose?

7. Use the step() to perform automated stepwise selection. Write down the best subset model? Also try Backward and forward selection using step() function. Do you see a difference in the results?

8. Try adding interaction terms and perform the automated stepwise selection again. Which interaction model did you arrive at?

9. On the final interaction model, perform a diagnostic analysis. What are your findings and conclusion?

10. Interpret and evaluate your final model.

Show more
LEARN MORE EFFECTIVELY AND GET BETTER GRADES!
Ask a Question