Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

23 Consider again the table given in question 21 with T points of X and Y where Y is a categorical variable taking values i]

image text in transcribed
image text in transcribed
23 Consider again the table given in question 21 with T points of X and Y where Y is a categorical variable taking values i] [Negative] or 1 (Positive). a} (5 points] Implement the Knearest neighbors [KNN] algorithm for K=l, K=3, and K=5. Write your classication values for each X value [-3J2,..., 2, 3} under the line as U or 1. The Y values in the data are shown by the colored dois where the blue dots are Y=D and red dots are Y=l. X-3-2-1D123 h} [2 points) Construct the confusion matrix for each K=1, 3, 5. Among K=3 and K=5, which one has the smallest 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

Elementary Linear Programming With Applications

Authors: Bernard Kolman, Robert E Beck

2nd Edition

0080530796, 9780080530796

More Books

Students also viewed these Mathematics questions

Question

Provide names for these compounds: b) a) , CO.H c) CH,0 d) NH2

Answered: 1 week ago