Question: Given the training data in the table below, Use Matlab to predict the class of the following new example using k-nearest neighbor for k =

Given the training data in the table below, Use Matlab to predict the class of the following new example using k-nearest neighbor for

k = 5: age

For similarity measure, use similarity (A,B) = where

are age, income, student or credit_rating

for income and 1 for student, age and credit_rating and

= 1 if and 0 otherwise.

Given the training data in the table below, Use Matlab to predict

age income student credit rating buys computer no no fair K-30 high 30 high no excellent no no fair 31...40 high yes yes >40 medium no fair yes >40 yes fair low no yes excellent >40 low 31...40 Dow yes excellent yes no 30 medium no fair K-30 low yes fair VeS >40 medium yes fair yes yes 30 medium yes excellent Wes 31...40 medium no excellent yes 31...40 high yes fair no >40 medium no excellent

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