nerdexam
Amazon

MLS-C01 · Question #150

A Data Scientist needs to create a model for fraud detection The dataset is composed of 2 years' worth of logged transactions, each with a small set of features All of the transactions in the…

The correct answer is C. Resample the dataset (oversamplinglundersampling), use the F1 score as the objective metric. To achieve optimal predictive power for fraud detection on a highly imbalanced dataset, the data scientist must address the class imbalance through resampling techniques and evaluate model performance using metrics suitable for such datasets.

Modeling

Question

A Data Scientist needs to create a model for fraud detection The dataset is composed of 2 years' worth of logged transactions, each with a small set of features All of the transactions in the dataset were manually labeled. Since fraud does not occur frequently, the dataset is highly imbalanced Less than 2% of the dataset was labeled as fraudulent. Which solution provides the optimal predictive power for classifying fraudulent activity?

Options

  • AOversample the dataset using a clustering technique, use accuracy as the objective metric, and
  • BUndersample the majority class in the dataset using a clustering technique, use precision as the
  • CResample the dataset (oversamplinglundersampling), use the F1 score as the objective metric,
  • DResample the dataset (oversamplinglundersampling), use accuracy as the objective metric, and

How the community answered

(21 responses)
  • A
    5% (1)
  • B
    19% (4)
  • C
    67% (14)
  • D
    10% (2)

Why each option

To achieve optimal predictive power for fraud detection on a highly imbalanced dataset, the data scientist must address the class imbalance through resampling techniques and evaluate model performance using metrics suitable for such datasets.

AOversample the dataset using a clustering technique, use accuracy as the objective metric, and

Using accuracy as the objective metric for a highly imbalanced dataset is misleading, as a model can achieve high accuracy by simply predicting the majority class, effectively ignoring the minority fraud class.

BUndersample the majority class in the dataset using a clustering technique, use precision as the

While undersampling and precision are relevant, relying solely on precision might lead to a model that misses a significant portion of actual fraudulent activities (low recall), which is generally undesirable in fraud detection.

CResample the dataset (oversamplinglundersampling), use the F1 score as the objective metric,Correct

Resampling the dataset (either oversampling the minority class or undersampling the majority class) directly addresses the class imbalance, and using the F1-score as the objective metric provides a balanced evaluation of precision and recall, which is crucial for accurately classifying rare fraudulent activities without excessive false positives.

DResample the dataset (oversamplinglundersampling), use accuracy as the objective metric, and

Similar to choice A, using accuracy as the objective metric for an imbalanced dataset is inappropriate because it does not adequately reflect the model's ability to correctly identify the minority class.

Concept tested: Handling imbalanced datasets in classification

Source: https://scikit-learn.org/stable/modules/imbalance.html

Topics

#Imbalanced Data#Fraud Detection#F1 Score#Resampling Techniques

Community Discussion

No community discussion yet for this question.

Full MLS-C01 Practice