Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

All work should be done in Rmarkdown. a. Import the data set in R. b. The data contains the variables y, X1, X2 and X3.

All work should be done in Rmarkdown.

a. Import the data set in R.

b. The data contains the variables y, X1, X2 and X3. The objective of this problem is to predict the response y based on X1, X2 and X3 and to determine which variables are significantly associated with the response. Perform a multiple regression to answer this question. Provide a prediction at X1=0.25, X2=0.5, X3=0 and compute the corresponding confidence and prediction intervals.

c. Analyze the residuals to detect potential problems with your analysis in part (b).

d. Propose solutions to the problems that you detect in part (c) and implement them on the data set. (Hint: studentized residual can be computed using the function studres(), cooks distance using cooks.distance() and the variance inflation factor using vif(). The function vif() is part of the R package car which you may need to install and unpack).

e. Rerun your analysis of part (a) on the data that you obtain from part (d)

f. Provide a prediction at X1=0.25, X2=0.5, X3=0 and compute the corresponding confidence and prediction intervals. Compare with the prediction in part (a) and comment on which you think is more believable.

CSV Dataset:

y X1 X2 X3
1 -0.13974 -1.57935 -1.34617 -1.41433
2 2.488086 -0.57187 -1.26539 1.276006
3 1.011556 -0.92886 -1.0788 -0.14422
4 1.165622 -0.24301 -0.17504 0.733503
5 4.649043 4 4 4
6 1.953061 0.700542 0.731804 1.370534
7 -1.62582 -0.33257 -0.12606 -1.67377
8 1.083962 0.659657 0.494654 -0.13043
9 0.340124 2.398158 2.371982 -0.59575
10 14.32947 -0.02441 0.065288 -1.48648
11 -0.58978 0.52045 0.145755 -1.65977
12 0.726325 0.023351 0.290523 -0.27464
13 -1.10236 0.976438 0.85155 -1.49602
14 -0.79743 0.856132 0.801864 -0.57978
15 1.480752 -1.31561 -0.84472 0.446083
16 1.229675 -0.24823 -0.14845 1.485359
17 1.96632 -0.99864 -1.12698 -0.61897
18 0.976957 0.233329 0.279988 0.134695
19 1.966958 -0.69696 -0.86249 -0.35512
20 1.256728 -2.02716 -1.92812 -0.32689
21 -0.80513 0.532601 0.636969 -0.83331
22 1.854674 -0.33745 -0.47086 1.965256
23 0.541499 -1.48426 -1.39756 1.577458
24 1.089738 0.204373 0.09211 -0.36165
25 0.078189 -0.92609 -0.58734 -0.4286
26 2.061862 0.724793 0.533103 -0.80344
27 -1.43315 -0.35087 0.492662 0.077635
28 1.448669 0.197459 0.830794 1.743172
29 0.178589 1.013231 0.378395 -0.31535
30 1.916939 1.631167 1.450821 1.528068
31 4.237683 1.055217 1.14351 0.624468
32 0.920624 -0.53846 -0.58541 0.086657
33 -1.86043 -1.22162 -0.59187 -1.67689
34 3.762859 0.172184 -0.17211 0.377145
35 -0.88401 -0.24194 0.029321 -0.4267
36 -0.52315 -1.89776 -1.96275 -1.0354
37 0.126189 -0.4823 -0.13735 -0.46304
38 2.070612 -0.48063 -0.23997 0.291548
39 1.13257 -0.04349 -0.48799 -1.53874
40 22.68859 0.522525 0.504895 -0.32639
41 0.136091 -0.43366 -0.38682 -0.97819
42 1.156993 -1.0903 -0.89352 0.76501
43 3.82853 0.532451 -0.20319 0.755096
44 1.221107 0.361146 0.195911 1.348398
45 1.041314 1.323331 1.132429 -0.82173
46 1.892013 -0.11903 -0.28024 0.564102
47 -0.49347 -1.65201 -1.44087 -0.02701
48 1.338495 0.555492 -0.11431 0.479503
49 -0.00525 -1.25138 -1.23692 -1.00535
50 1.797629 1.618357 1.481285 0.352339
51 1.835434 -0.05603 -0.54597 0.358386
52 -0.43076 -1.61015 -1.33457 -1.08578
53 1.674145 0.222043 0.23747 0.55527
54 0.042195 0.531664 0.585509 -0.5956
55 6.995337 7 7 7
56 1.543632 0.866354 0.957288 1.180073
57 -0.24317 -1.05728 -1.19455 -0.4956
58 3.12185 -0.70591 -0.75188 0.460147
59 0.483944 -0.89088 -1.19349 -0.54788
60 1.999361 0.873917 0.109992 -0.98237
61 -1.22557 -0.90096 -0.805 -1.9767
62 3.108234 -0.56767 -0.98345 0.669159
63 2.068185 0.518263 0.459208 2.095664
64 3.14748 -0.1123 -0.19435 -0.11372
65 1.87294 0.723735 0.512689 0.414106
66 -0.32897 -1.05589 -0.79708 -0.93997
67 -0.42078 0.331518 -0.39251 -1.38677
68 -0.14891 0.209127 0.2234 -1.05578
69 0.07276 0.074816 0.19088 -0.03074
70 1.252791 0.828345 0.841857 -0.38103
71 2.669516 -0.08881 -0.32376 0.355655
72 1.225813 0.071241 -0.00528 -1.06167
73 2.238608 1.019657 0.584553 1.117346
74 1.100568 2.585262 2.156504 -0.51891
75 0.741882 0.567485 0.708091 -0.18181
76 0.682697 0.344694 0.724861 -0.02013
77 -0.1959 0.621958 0.765381 0.457507
78 1.822856 -1.19205 -1.05587 0.320659
79 2.224579 0.026357 -0.01412 -0.02065
80 0.379759 -1.0436 -1.44512 -0.72497
81 -1.25078 -1.40587 -1.06488 -1.1871
82 0.583607 -0.25228 -0.61441 -0.32231
83 -0.22195 0.250115 0.085179 -2.08031
84 -0.29961 -0.57325 -0.66251 -0.90333
85 10.69494 10 10 10
86 1.26254 -1.58333 -1.46986 -1.12819
87 0.528116 0.126447 -0.49342 -0.69019
88 -0.94262 0.981458 1.044326 -1.92891
89 1.655922 -0.09909 -0.08877 0.433304
90 1.062591 -0.02393 -0.00069 0.098235
91 1.447929 -0.07977 0.020929 0.420904
92 1.717465 2.600088 2.523351 0.426792
93 1.48326 1.183439 1.455622 1.300968
94 1.761339 -1.5212 -1.47039 0.395716
95 0.939341 1.305107 1.049782 0.190679
96 2.959013 1.139882 1.056413 0.456473
97 3.530812 0.328364 -0.45995 -0.95753
98 3.171855 -0.91385 -0.67654 1.061604
99 0.716547 -0.58186 -0.93246 -0.58608
100 -7.63368 -0.07955 -0.41231 1.097491
101 -0.68884 0.0498 0.122259 -0.44188
102 4.213887 -1.31635 -1.38559 2.937882
103 0.65755 -1.5233 -1.2219 0.90683
104 0.173327 0.49946 0.103395 0.96015
105 -0.30375 -0.03896 0.345797 1.479302
106 2.184872 0.058022 0.365487 0.731148
107 1.832573 -0.182 -0.17394 0.794146
108 2.607312 -0.42957 -0.76049 0.774902
109 -3.57045 1.511565 1.924703 -0.91906
110 0.59508 1.020841 1.121637 0.553878
111 2.685347 1.391235 1.192741 0.858667
112 4.559919 -0.90839 -0.98679 1.751437
113 1.150801 0.59292 0.356462 0.006702
114 1.45246 -1.57096 -1.52154 0.537717
115 0.016635 1.31865 1.04875 -1.40991
116 -1.41066 0.861762 1.115254 -0.76253
117 1.462585 -0.02601 0.081333 0.640087
118 2.78867 -0.21695 -0.35918 1.096938
119 1.151586 1.248431 0.858669 -0.60689
120 1.483344 -0.15309 -0.36871 0.531345
121 2.011559 0.490011 0.556287 0.79885
122 0.464704 -1.26462 -0.59501 0.11553
123 2.115236 -1.7513 -1.23501 0.561604
124 1.273652 0.225144 0.256408 0.583781
125 0.516135 -0.0998 -0.11276 -0.81249
126 2.632117 -0.25837 -0.34332 -0.31482
127 0.544228 -0.88157 -0.9963 0.333612
128 0.350162 0.323966 0.114899 -0.54838
129 1.125723 -2.13616 -1.68356 -0.12151
130 2.073527 -0.84013 -1.15838 -0.35126
131 3.802088 0.911418 0.331477 -0.85194
132 1.478994 0.065344 0.302306 0.036662
133 -0.81066 0.250256 0.350838 -0.98773
134 -0.00863 0.378573 0.287574 -1.02362
135 -0.5931 0.362028 0.323819 0.043896
136 2.48176 -1.31671 -1.08719 -0.53541
137 0.308454 -0.65175 -0.69624 0.591709
138 1.701149 -1.71038 -1.83972 -0.15953
139 1.749884 0.132774 -0.27191 -0.21273
140 1.898686 -0.10712 -0.18783 -0.66818
141 -0.41778 -0.52517 -0.39712 -1.7105
142 -0.4553 0.837886 0.453318 -1.80055
143 2.373133 -0.81487 -0.39459 1.627487
144 3.646147 1.152229 1.142577 1.606081
145 -2.12608 0.182426 0.013601 -2.66538
146 0.187404 0.789967 0.645408 -1.89156
147 -1.52195 0.421663 0.987326 -0.93076
148 0.761474 0.497063 0.434959 -0.48496
149 2.524247 -0.03999 -0.45188 0.822471
150 1.673569 0.507875 0.485312 0.428643

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

International Marketing And Export Management

Authors: Gerald Albaum , Alexander Josiassen , Edwin Duerr

8th Edition

1292016922, 978-1292016924

Students also viewed these Mathematics questions