Answer 2022-23
Answer 2022-23
Practical Example:
• A fruit classification task:
o Kkk=3: A fruit is classified based on the
labels of its 3 nearest neighbors.
o Kkk=10: A smoother decision boundary is
created, but small clusters may be
ignored.
positive cases.
▪ True Negative (TN): Correctly predicted
negative cases.
▪ False Positive (FP): Incorrectly predicted
positives.
▪ False Negative (FN): Incorrectly predicted
negatives.
o Example: In email spam classification:
▪ TP: Emails correctly classified as spam.
▪ TN: Emails correctly classified as not
spam.
▪ FP: Genuine emails wrongly classified as
spam.
▪ FN: Spam emails wrongly classified as
genuine.
o Performance Metrics: Accuracy, precision, recall,
and F1-score are derived from the matrix.
(b) Calculate the accuracy percentage for the given
Confusion Matrix.
Expanded Answer:
o Given Confusion Matrix:
▪ TP = 12, TN = 9, FP = 3, FN = 1.
o Accuracy Formula: Accuracy = (TP + TN) / Total
= (12 + 9) / 25 = 84%.
• 10: Supervised Feature Selection Techniques and
Related Concepts
• (a) Explain three techniques under supervised
feature selection:
• Filter Method:
• Overview: Features are ranked based on their
correlation with the target variable, without
involving a predictive model.
• Example Techniques:
• Chi-square test: Evaluates the dependency
between categorical features and target variables.
• ANOVA (Analysis of Variance): Measures how
different groups (e.g., classes) vary with respect to
numerical features.
• Illustration: A dataset with student performance—
Chi-square can identify if "study hours" are
significantly related to "exam scores."
• Advantages: Computationally inexpensive and
fast.
• Wrapper Method:
•