Notice: Due to an ongoing migration of our storage and publishing system, material requested since last month will not be uploaded for the time being, and new requests are paused. All existing notes remain available.
Which of the following algorithms is categorized as a 'Lazy Learner'?
Not quite. Try another option.
Answer: K-Nearest Neighbors
K-Nearest Neighbors (k-NN) is a lazy learner because it does not build a model during the training phase; instead, it stores the training data and performs computation only when a prediction is requested.
Question 2 of 50
In K-Nearest Neighbors, what is the likely effect of choosing a very small value for 'k' (e.g., k=1)?
Not quite. Try another option.
Answer: High variance and overfitting
A very small 'k' makes the model extremely sensitive to noise in the training data, leading to complex decision boundaries and overfitting (high variance).
Question 3 of 50
Which distance metric is most commonly used in k-NN for continuous numerical variables?
Not quite. Try another option.
Answer: Euclidean distance
Euclidean distance is the standard metric used to calculate the straight-line distance between two points in Euclidean space for continuous numerical data.
Question 4 of 50
Why is feature scaling (normalization/standardization) important in k-NN?
Not quite. Try another option.
Answer: To prevent features with larger scales from dominating the distance calculation
Since k-NN relies on distance calculations, features with large magnitudes will outweigh features with smaller magnitudes unless they are scaled to a comparable range.
Question 5 of 50
The 'Naïve' in Naïve Bayes refers to which fundamental assumption?
Not quite. Try another option.
Answer: All features are conditionally independent given the class
The algorithm assumes that the presence of a particular feature in a class is unrelated to the presence of any other feature, simplifying the calculation of posterior probabilities.
Question 6 of 50
Naïve Bayes is based on which mathematical theorem?
Not quite. Try another option.
Answer: Bayes' Theorem
Naïve Bayes classifiers apply Bayes' theorem to calculate the probability of a class given a set of feature values.
Question 7 of 50
What is the purpose of Laplace Smoothing in Naïve Bayes?
Not quite. Try another option.
Answer: To handle the problem of zero probability for unseen features
If a feature value never occurs with a specific class in the training set, the probability becomes zero, wiping out the entire calculation. Laplace smoothing adds a small count to all probabilities to prevent this.
Question 8 of 50
Which strategy is primarily used to build Decision Trees?
Not quite. Try another option.
Answer: Divide and Conquer
Decision trees use a recursive divide-and-conquer strategy (recursive partitioning) to split the data into subsets based on feature values.
Question 9 of 50
In a Decision Tree, what does a leaf node represent?
Not quite. Try another option.
Answer: A class label or decision
Leaf nodes (terminal nodes) represent the final outcome, class label, or decision value after traversing the tree rules.
Question 10 of 50
Which metric is commonly used to measure impurity in Decision Trees?
Not quite. Try another option.
Answer: Gini Index
The Gini Index (or Entropy) is used to measure the impurity or disorder of a set of samples to determine the best split.
Question 11 of 50
The process of removing branches from a decision tree to prevent overfitting is called:
Not quite. Try another option.
Answer: Pruning
Pruning reduces the size of decision trees by removing sections of the tree that provide little power to classify instances, thereby reducing complexity and overfitting.
Question 12 of 50
Which concept represents the expected reduction in entropy caused by partitioning the examples according to an attribute?
Not quite. Try another option.
Answer: Information Gain
Information Gain measures the change in entropy (information) from a prior state to a state that takes some information is given, used to select the best split attribute.
Question 13 of 50
In rule-based classification, what does 'coverage' refer to?
Not quite. Try another option.
Answer: The number of instances that satisfy the rule's condition
Coverage is the fraction or number of instances in the dataset that trigger the rule (i.e., satisfy the antecedent conditions).
Question 14 of 50
The OneR (One Rule) algorithm generates rules based on:
Not quite. Try another option.
Answer: The single most informative attribute
OneR generates a simple rule set based on only one attribute—the one that yields the minimum error rate on the training data.
Question 15 of 50
What is the primary objective of a Support Vector Machine (SVM)?
Not quite. Try another option.
Answer: Find a hyperplane that maximizes the margin between classes
SVM aims to find the optimal hyperplane that separates data points of different classes with the maximum distance (margin) between the nearest points of each class.
Question 16 of 50
The data points that lie closest to the decision boundary in an SVM are known as:
Not quite. Try another option.
Answer: Support Vectors
Support vectors are the data points closest to the hyperplane. They are critical because they define the position and orientation of the hyperplane.
Question 17 of 50
What technique does SVM use to handle non-linearly separable data?
Not quite. Try another option.
Answer: Kernel Trick
The Kernel Trick projects data into a higher-dimensional space where it becomes linearly separable, without explicitly computing the coordinates in that space.
Question 18 of 50
In SVM, what is the role of the 'C' hyperparameter?
Not quite. Try another option.
Answer: It controls the trade-off between maximizing the margin and minimizing classification errors
A low 'C' allows more misclassifications (soft margin) for a wider margin, while a high 'C' penalizes misclassifications heavily (hard margin), potentially leading to overfitting.
Question 19 of 50
In a Confusion Matrix, what does 'False Positive' (Type I Error) represent?
Not quite. Try another option.
Answer: Incorrectly predicting the positive class when it is actually negative
A False Positive occurs when the model predicts the positive class, but the true value is negative (e.g., diagnosing a healthy person as sick).
Question 20 of 50
Which formula correctly calculates Accuracy?
Not quite. Try another option.
Answer: (TP + TN) / (TP + TN + FP + FN)
Accuracy is the ratio of correctly predicted observations (both True Positives and True Negatives) to the total observations.
Question 21 of 50
Accuracy is often a misleading metric when:
Not quite. Try another option.
Answer: The dataset is imbalanced
In imbalanced datasets (e.g., 99% Class A, 1% Class B), a model predicting only Class A achieves 99% accuracy but fails to detect Class B, making accuracy misleading.
Question 22 of 50
Which metric represents the ratio of correctly predicted positive observations to the total predicted positives?
Not quite. Try another option.
Answer: Precision
Precision = TP / (TP + FP). It answers the question: 'Of all the instances predicted as positive, how many were actually positive?'
Question 23 of 50
Recall is also known as:
Not quite. Try another option.
Answer: Sensitivity
Recall (TP / (TP + FN)) is synonymous with Sensitivity or True Positive Rate.
Question 24 of 50
The F1 Score is the harmonic mean of which two metrics?
Not quite. Try another option.
Answer: Precision and Recall
F1 Score balances Precision and Recall, providing a single metric that penalizes extreme values in either.
Question 25 of 50
Which metric would be most important for a spam detection system where it is acceptable to miss some spam, but critical not to delete legitimate emails (high cost of False Positive)?
Not quite. Try another option.
Answer: Precision
High Precision minimizes False Positives. In this scenario, marking a legitimate email as spam (False Positive) is the worst outcome.
Question 26 of 50
Which metric would be most important for cancer detection where missing a positive case is dangerous (high cost of False Negative)?
Not quite. Try another option.
Answer: Recall
High Recall ensures that most actual positive cases are detected, minimizing False Negatives.
Question 27 of 50
What does AUC stand for in the context of model evaluation?
Not quite. Try another option.
Answer: Area Under the Curve
AUC refers to the Area Under the ROC (Receiver Operating Characteristic) Curve.
Question 28 of 50
The ROC curve plots which two metrics against each other?
Not quite. Try another option.
Answer: True Positive Rate vs False Positive Rate
The ROC curve shows the trade-off between the True Positive Rate (Recall) on the y-axis and the False Positive Rate on the x-axis at various threshold settings.
Question 29 of 50
An AUC score of 0.5 indicates:
Not quite. Try another option.
Answer: A model that predicts randomly
An AUC of 0.5 suggests the model has no discriminative ability, effectively guessing as well as a random coin toss. A perfect model has an AUC of 1.0.
Question 30 of 50
Logarithmic Loss (Log Loss) penalizes a classifier based on:
Not quite. Try another option.
Answer: The confidence of the predicted probabilities
Log Loss takes into account the uncertainty of your prediction based on how much it varies from the actual label. A confident wrong prediction is penalized heavily.
Question 31 of 50
What is the ideal value for Logarithmic Loss?
Not quite. Try another option.
Answer: 0
Log Loss measures error, so lower is better. A value of 0 represents a perfect model.
Question 32 of 50
Which of the following is a disadvantage of Decision Trees?
Not quite. Try another option.
Answer: Prone to overfitting if not pruned
Decision trees can become very complex and memorize noise in the training data (overfitting) if constraints or pruning are not applied.
Question 33 of 50
Which algorithm is generally considered a 'Black Box' model due to low interpretability?
Not quite. Try another option.
Answer: Support Vector Machines (with RBF kernel)
SVMs, especially with non-linear kernels, operate in high-dimensional spaces that are difficult for humans to visualize or interpret compared to logic-based trees or rules.
Question 34 of 50
In Naïve Bayes, what is the 'Posterior Probability'?
Not quite. Try another option.
Answer: The probability of the class given the evidence
The posterior probability P(Class|Features) is the updated probability of the class after observing the feature data.
Question 35 of 50
Which classification algorithm is parametric?
Not quite. Try another option.
Answer: Naïve Bayes
Naïve Bayes is a parametric algorithm because it summarizes data with a fixed set of parameters (means and variances for Gaussian NB, or probabilities) rather than storing the data itself.
Question 36 of 50
What is the 'Hinge Loss' function associated with?
Not quite. Try another option.
Answer: Support Vector Machines
Hinge loss is the loss function used for training classifiers like SVMs, penalizing predictions that are on the wrong side of the margin.
Question 37 of 50
What happens to the computational cost of k-NN during the prediction phase as the dataset size grows?
Not quite. Try another option.
Answer: It increases significantly
Because k-NN is a lazy learner, it scans the entire training dataset to calculate distances for every new prediction, making it slow for large datasets.
Question 38 of 50
Entropy in Information Theory is a measure of:
Not quite. Try another option.
Answer: Disorder or Uncertainty
Entropy quantifies the amount of uncertainty or impurity in a dataset. A completely homogeneous set has an entropy of 0.
Question 39 of 50
RIPPER (Repeated Incremental Pruning to Produce Error Reduction) is an algorithm used for:
Not quite. Try another option.
Answer: Rule Induction
RIPPER is a popular algorithm for generating a set of IF-THEN rules to classify data.
Question 40 of 50
Which of the following describes a 'False Negative' (Type II Error)?
Not quite. Try another option.
Answer: Predicting Negative when actually Positive
A False Negative misses a positive instance, classifying it as negative (e.g., failing to detect a fire).
Question 41 of 50
If Precision = 1.0 and Recall = 1.0, what is the F1 Score?
Not quite. Try another option.
Answer: 1.0
F1 Score is the harmonic mean. If both inputs are 1, the mean is 1. (211)/(1+1) = 1.
Question 42 of 50
Which evaluation metric calculates the proportion of actual negatives that are correctly identified?
Not quite. Try another option.
Answer: Specificity
Specificity = TN / (TN + FP). It measures the model's ability to identify negative instances.
Question 43 of 50
In a decision tree, if a node contains only samples from a single class, its entropy is:
Not quite. Try another option.
Answer: 0
If a node is pure (all samples belong to one class), there is no disorder, so Entropy is 0.
Question 44 of 50
Which kernel is the default for non-linear SVMs in many libraries?
Not quite. Try another option.
Answer: Radial Basis Function (RBF)
RBF is the most commonly used kernel for non-linear SVM classification because it handles infinite dimensional space effectively.
Question 45 of 50
Generative models like Naïve Bayes model:
Not quite. Try another option.
Answer: The distribution of individual classes (Joint probability)
Generative models learn how the data is generated (P(X|Y) and P(Y)) to estimate P(Y|X), whereas discriminative models learn the boundary directly.
Question 46 of 50
Recursive Partitioning is a technique synonymous with:
Not quite. Try another option.
Answer: Building Decision Trees
Recursive partitioning splits the data into smaller subsets repeatedly, which is the process used to construct decision trees.
Question 47 of 50
When interpreting a Confusion Matrix for a multi-class problem (e.g., 3 classes), the matrix dimensions are:
Not quite. Try another option.
Answer: 3x3
A confusion matrix size is N x N, where N is the number of classes.
Question 48 of 50
Which algorithm is most sensitive to outliers?
Not quite. Try another option.
Answer: K-Nearest Neighbors
Since k-NN relies on local distance to neighbors, a single outlier can significantly skew predictions if 'k' is small.
Question 49 of 50
What is the relationship between Error Rate and Accuracy?
Not quite. Try another option.
Answer: Error Rate = 1 - Accuracy
They are complementary. If Accuracy is 90% (0.9), the Error Rate is 10% (0.1).
Question 50 of 50
The 'Zero Frequency' problem in Naïve Bayes is solved using:
Not quite. Try another option.
Answer: Laplace Smoothing
Laplace smoothing adds a small count (usually 1) to frequency counts to ensure no probability is ever essentially zero.
That's unit 3
Answer a few questions and your score shows up here.
Nearly through. Did unit 3 of INT234 save you a night before the exam?
LPU Notes is free. A student pays for the servers.
Did unit 3 of INT234 save you a night before the exam?
Then you can help keep it free for the next batch. Ads cover part of the server bill;
the rest comes out of a student's own pocket: the domain, the storage, and keeping
the site up through the weeks everyone needs it at once.
The payment button didn't load. An ad blocker or a filtered network is the usual reason.
to try again.