Supervised Learning Algorithms Flashcards
7 cards from real Data Science practice questions. Tap to flip, then mark Knew It or Still Learning โ missed cards come back until you master them.
Read the first 7 Supervised Learning Algorithms flashcards as text
What is the bias-variance tradeoff?
Answer: Balancing underfitting (high bias) against overfitting (high variance)
The bias-variance tradeoff balances errors from overly simple models (bias) and overly complex ones (variance).
Why is cross-validation preferred over a single train-test split?
Answer: It gives a more robust estimate of model performance across folds
Cross-validation averages performance over multiple folds, giving a more reliable generalization estimate.
In multiclass classification, what does the softmax function produce?
Answer: A probability distribution over all classes summing to 1
Softmax converts raw scores into a probability distribution across classes that sums to one.
What is a key disadvantage of k-nearest neighbors at prediction time?
Answer: It is computationally expensive because it stores and searches all training data
k-NN is a lazy learner that searches the entire training set at inference, making prediction slow.
Which scenario most likely indicates an underfitting model?
Answer: High training error and high test error
High error on both training and test sets indicates the model is too simple, i.e., underfitting.
What does the ROC curve plot?
Answer: True positive rate against false positive rate
The ROC curve plots the true positive rate versus the false positive rate across thresholds.
In gradient descent, what happens if the learning rate is set too high?
Answer: The algorithm may overshoot and diverge
A learning rate that is too high can cause updates to overshoot the minimum and diverge.