Practice
1. For a time series dataset, which cross-validation method is more appropriate and why?
medium
Solution
Step 1: Identify the need to respect temporal order.
Time series data requires maintaining the order of data points.Step 2: Eliminate wrong options.
K-Fold (A) and Stratified K-Fold (B) do not respect temporal order, Leave-One-Out (D) is computationally expensive and doesn't address temporal order.Final Answer:
Option A -> Option AQuick Check:
Time series needs temporal order. [OK]
Hint: Time series needs temporal order. [OK]
Common Mistakes:
2. A model performs well overall but poorly on a specific slice of data. What is the most likely cause?
medium
Solution
Step 1: Analyze the problem
Poor performance on a specific slice often indicates distribution mismatch.Step 2: Eliminate wrong options
The model is overfitting to the training data. is incorrect as overfitting would affect overall performance. The model has too many parameters. is unrelated to slice-specific issues. The learning rate is too high. affects convergence, not slice performance.Final Answer:
Option A -> Option AQuick Check:
Slice mismatch = distribution issue. [OK]
Hint: Slice mismatch = distribution issue. [OK]
Common Mistakes:
3. A company implemented an ML model to predict customer churn but found that the model's predictions were not improving business outcomes. What is the most likely root cause?
medium
Solution
Step 1: Identify the mismatch
If the model's predictions are not improving business outcomes, it is likely that the business problem was not correctly translated into an ML problem.Step 2: Eliminate wrong options
The model is overfitting the training data is incorrect because overfitting would affect prediction accuracy, not business alignment. The model's hyperparameters were not optimized is incorrect because hyperparameter tuning affects model performance, not problem alignment. The dataset used was too small is incorrect because data size affects model accuracy, not problem framing.Final Answer:
Option B -> Option BQuick Check:
Align ML problem with business goals for impact. [OK]
Hint: Align ML problem with business goals for impact. [OK]
Common Mistakes:
4. A Lasso regression model is underperforming with high bias. What is the most likely cause?
medium
Solution
Step 1: Identify the effect of high alpha in Lasso.
High alpha increases regularization strength, leading to high bias.Step 2: Eliminate wrong options.
Large datasets do not cause overfitting. High complexity increases variance, not bias. Non-normalized features affect scale, not bias directly.Final Answer:
Option D -> Option DQuick Check:
High alpha = high bias in Lasso. [OK]
Hint: High alpha = high bias in Lasso. [OK]
Common Mistakes:
5. When deciding between a rule-based system and a machine learning model for a task, which scenario favors a rule-based approach?
medium
Solution
Step 1: Identify the nature of the task.
Rule-based systems excel in tasks with clear, logical rules.Step 2: Eliminate tasks requiring pattern recognition.
Options A, B, and D involve pattern recognition, which is better suited for ML.Final Answer:
Option A -> Option AQuick Check:
Rules for logic, ML for patterns. [OK]
Hint: Rules for logic, ML for patterns. [OK]
Common Mistakes:
