Question: Exercise 1 3 - 9 Algo ( Using R ) The answers to this problem are based on R version 3 . 5 . 3

Exercise 13-9 Algo (Using R)
The answers to this problem are based on R version 3.5.3. To replicate the results with newer versions of R, execute the following
line of code at the beginning of the R session or your R code: suppressWarnings(RNGversion("3.5.3")).
For R, partition data sets into 70% training and 30% validation. Use the statement set.seed(1) to specify the random seed of 1 for both
data partitioning and cross-validation. If the predictor variable values are in the character format, then treat the predictor variable as a
categorical variable. Otherwise, treat the predictor variable as a numerical variable.
The accompanying data file contains five predictor variables (x1 to x5) and one binary target variable (y). Follow the instructions below
to create classification trees using the Exercise 13.9 Data worksheet.
a. Use the rpart function to build a default classification tree. How many leaf nodes are in the default classification tree? What are the
predictor variable and split value for the first split of the default classification tree (root node)?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!