Question: 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

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: suppress Warnings (RNG version("3.5.3")). For R, partition data sets into 60% training and 40% 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 set contains two predictor variables (x1, x2) and the target variable (y). Partition the data to develop a naïve Bayes classification model where ‘Y’ denotes the positive or success class for y.

a. Report the accuracy, specificity, sensitivity, and precision rates for the validation data set.
b-1. What is the area under the ROC curve (or the AUC value)?

b-2. Is the following statement a true statement? The ROC curve shows that the naïve Bayes model performs better than the baseline model in terms sensitivity and specificity across all possible cutoff values.

  • True

  • False

c. Report the scoring results for the five new observations.





Scoring result for first new observation
Scoring result for second new observation
Scoring result for third new observation
Scoring result for fourth new observation
Scoring result for fifth new observation
yx1x2
YA1
YB0
YC0
YB0
NC0
NA0
NA1
NA1
NB1
YC0
NB1
YC0
NB1
YC0
NA1
YC1
NA1
YC0
NC0
YC1
NB1
NB0
NB1
YA0
YC1
YC0
NC0
NB1
NB1
NA0
YC0
NB0
NC1
YB1
YA0
YA1
NB0
NC1
YC0
NB1
YB1
NA1
YA1
NA0
YA0
NB0
NB1
NA1
YC0
YA0
NB0
NA0
YB1
YB1
YC1
YC0
YB0
NA1
YA1
NB0
NC0
YA0
NA1
NC0
NC1
YC1
YC0
YB0
NB0
YC0
NC0
YA0
NC1
NB0
NC0


x1x2
A0
B1
C1
B0
C0


Step by Step Solution

3.36 Rating (149 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

a The accuracy specificity sensitivity and precision rates for the validation data set can be calculated using the confusion matrix The confusion matr... View full answer

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 Marketing Questions!