Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please use R to solve this question and include the R codes. I have found many solutions for this question but i do not know

please use R to solve this question and include the R codes.

I have found many solutions for this question but i do not know which is the correct one.

image text in transcribed
Use the 0.] data set which is part of the ISLE. package. (a) Create a training set containing a random sample of 80-0 observations, and a test set containing the remaining observations. (b) Fit a tree to the training data, which purchase as the response and the other variables except for Store as predictors. Use the summary\" function to produce summary statistics about the treeJ and describe the results obtained. 1What is the training error rate? HOW many terminal nodes does the tree have? (c) Create a plot of the treeJ and interpret the results. (d) Predict the response on the test data, and produce a confusion matrix comparing the test labels to predicted test labels. What is the test error rate

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored 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

College Algebra Enhanced With Graphing Utilities (Subscription)

Authors: Michael Sullivan, Michael Sullivan III

8th Edition

0135812380, 9780135812389

More Books

Students also viewed these Mathematics questions

Question

6. How can hidden knowledge guide our actions?

Answered: 1 week ago

Question

7. How can the models we use have a detrimental effect on others?

Answered: 1 week ago