Skip to content
Past Exams

Master Machine Learning Concepts

Explore a binary classification problem using K-Nearest Neighbors (K-NN) with two real-valued features. Analyze training data visually and apply distance-based classification techniques to predict outcomes. From a Fall 2021 ML course assignment.

Preview 2 of 5 pages

See the first 2 pages exactly as they appear in the document.

  1. Page 1
    Read page 1 as text

    CS 178 Midterm Exam Machine Darning and Data Mining: Fall 202-1 Wednesday' Novemter 6th, 2024 • Please put your name and ID on every page. • Total time is Sil minutes. READ THE EXAM FIRST and organize your time; don't spend too long on any one problem . • Please write clearly and show all your work. • If you need clarification on a problem, please raise your hand and wait for the instructor or TA to come over. • You may use one sheet containing handwritten notes for reference. and a (basic) calculator. • T urn in your notes and any scratch pa]w:r with your exam . Problems 1 K-Nearest Neighbors t 15 points.) 3 2 Neural Networks, (15 point#,) 5 3 Support Vector Machines, (15 points,) 7 4 Naive Bayes Classifiers fl 5 points,) 1)

  2. Page 2
    Read page 2 as text

    Problem 1 K-Nearcst Ncighljors, (15 points.) Fur a classification problem to predict binary p given two real- valnrd features z , , Xj , we ohairve training data {pictured at r i g h t ) : J l y 1.0 0.5 -1 2.0 0.5 -1 2.0 2.5 -1 3.0 1.5 1 4.0 .1.0 1 2.0 4.5 1 (1| On the data plot, sketch the decision lioiindary of a 1-nearest neigh lx>r classifier trained on the data. (.? points.) (2) What is the training error rate of the resulting 1-neamst neighbor classifier? (Tn ease of any tics, we prefer to predict class + 1.) (-? pointsJ It 1 Train Itnz (3) What is thn teone-onc-out eross-fjaJidstton errwr rate of a ]-nrarcst-ucighlxjr? f .? points.J 4 1 LOOXV Hm (4) What is tlie trainitrg error rate of a 3-ncarcst neighbor classifier trained on these data? (,7 pointe.) 4 4 Train Em (5) What is the the tearjc-onc-out cross mlidafion error rote of a nearest naghbor classifier trained un the data? (‘J pf/intx.) 4 a LOOXV Em

3 more pages in the full document

Unlock it once and it stays in your library, ready to chat with or turn into flashcards.

Unlock the full document
See all

Study this document with CramX

Once it is in your library, every tool can work from it.