Practice
1. In a binary classification problem where false positives are costly, which metric should be prioritized?
easy
Solution
Step 1: Identify the cost concern.
False positives are costly, so we need to minimize them.Step 2: Choose the metric that minimizes false positives.
Precision is the metric that focuses on minimizing false positives.Final Answer:
Option A -> Option AQuick Check:
Precision minimizes false positives. [OK]
Hint: Precision minimizes false positives. [OK]
Common Mistakes:
2. In a dataset with missing values in a numerical feature, which imputation strategy is most appropriate when the data is normally distributed?
easy
Solution
Step 1: Identify the distribution of the data
For normally distributed data, the mean is the best measure of central tendency.Step 2: Eliminate wrong options
Median is better for skewed data, mode for categorical data, and zero imputation can distort the distribution.Final Answer:
Option D -> Option DQuick Check:
Mean for normal distribution [OK]
Hint: Mean for normal distribution [OK]
Common Mistakes:
3. In the context of Random Forests, what is the primary purpose of using bagging?
easy
Solution
Step 1: Understand bagging's role
Bagging, or Bootstrap Aggregating, is used to reduce variance by averaging predictions from multiple models trained on different subsets of the data.Step 2: Eliminate wrong options
To increase the model's interpretability is incorrect because bagging does not inherently increase interpretability. To enhance the model's feature selection is wrong as feature selection is not the primary goal of bagging. To improve the model's computational efficiency is incorrect because bagging typically increases computational cost due to multiple models.Final Answer:
Option D -> Option DQuick Check:
Bagging reduces variance by averaging. [OK]
Hint: Bagging reduces variance by averaging. [OK]
Common Mistakes:
4. When comparing two models using statistical significance, which approach is more appropriate if you have a small sample size?
medium
Solution
Step 1: Consider sample size constraints
With small sample sizes, non-parametric tests are more reliable as they do not assume normal distribution.Step 2: Eliminate inappropriate tests
Use a t-test assuming equal variances. assumes equal variances which may not hold. Use a z-test assuming normal distribution. assumes normal distribution, which is unreliable with small samples. Use a chi-squared test for independence. is for categorical data, not model comparison.Final Answer:
Option B -> Option BQuick Check:
Small samples? Use non-parametric tests [OK]
Hint: Small samples? Use non-parametric tests [OK]
Common Mistakes:
5. How would you adapt Naive Bayes for a text classification task where word order matters?
hard
Solution
Step 1: Understand the Task Requirements
Word order matters, so capturing sequences is important.Step 2: Evaluate Adaptation Options
Use a bag-of-words model. ignores word order. Use a single Gaussian distribution for all features. is irrelevant to text data. Apply PCA to reduce dimensionality. reduces dimensionality but doesn't capture order. Incorporate n-grams into the feature set. captures sequences with n-grams.Final Answer:
Option C -> Option CQuick Check:
Use n-grams for word order in text. [[check]]
Hint: Use n-grams for word order in text. [[check]]
Common Mistakes:
