← Boston Consulting Group Interview Insights
The scenario itself wasn't hard to parse but I spent way too long debating IQR vs Z-score instead of just picking one and moving.
Start by clarifying the data structure and business context, then walk through a reproducible Python workflow: load and aggregate daily revenue per SKU, visualize the raw distribution, apply IQR or Z-score to flag outliers, remove them, and re-plot to compare. Emphasize that outlier removal should be justified and validated, not automatic, and discuss trade-offs between methods and their impact on downstream analysis.
Pro tip: Always investigate outliers before removing them—some may be legitimate high-value sales or data errors; document your decision and consider robust alternatives like winsorizing or log transformation. This shows business acumen and statistical maturity.
Ask about the data granularity, time period, and whether outliers could represent real events (e.g., promotions, bulk orders) or errors. Confirm the definition of daily revenue per SKU (e.g., sum of sales).
Use pandas to group by SKU and date, calculate daily revenue, then plot a histogram with matplotlib/seaborn. Describe the shape, skewness, and potential outliers visually.
Implement both methods: IQR (Q1 - 1.5*IQR, Q3 + 1.5*IQR) and Z-score (|z| > 3). Discuss pros and cons: IQR is robust to non-normal data, Z-score assumes normality and is sensitive to extreme values.
Filter out flagged outliers, then re-plot the cleaned distribution. Compare side-by-side with the original to show the effect. Mention that removal should be justified and consider alternative treatments like capping.
Check how many data points were removed and whether the cleaned distribution makes business sense. Discuss potential impact on downstream metrics and suggest sensitivity analysis or robust methods.
AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.