Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Check image 1 for question and image 2 for dataset structure: write a pyrhon code (a) Using the NumPy or Pandas package, load the dataset.

Check image 1 for question and image 2 for dataset structure:

image text in transcribed

image text in transcribed

write a pyrhon code
(a) Using the NumPy or Pandas package, load the dataset. (Dataset "breast_cancer_wisconsin.csv" is uploaded for this assignment). Then split the dataset into train and test sets with a test ratio of 0.3. (b) Using the scikit-learn package, define a DT classifier with custom hyperparameters and fit it to your train set. Measure the precision, recall, F-score, and accuracy on both train and test sets. Also, plot the confusion matrices of the model on train and test sets. (c) Study how maximum tree depth and cost functions of the following can influence the efficiency of the Decision Tree on the delivered dataset. Describe your findings. i. three different cost functions: ['gini', 'ent ropy' , 'log_loss'] ii. six different maximum tree depth: [2,4,6,8,10,12] (d) Depict a plot of the decision boundary of the two mentioned hyperparameters. Comment on the fundamental features in short

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

Put Your Data To Work 52 Tips And Techniques For Effectively Managing Your Database

Authors: Wes Trochlil

1st Edition

0880343079, 978-0880343077

More Books

Students also viewed these Databases questions

Question

How do Dimensional Database Models differ from Relational Models?

Answered: 1 week ago

Question

What type of processing do Relational Databases support?

Answered: 1 week ago

Question

Describe several aggregation operators.

Answered: 1 week ago