Data Science level task. **Condition:** Find days with anomalous sales — when the daily sum deviates from the moving average by more than 2 standard deviations. **Table:** sales (amount, sale_date, ...) **Requirements:** 1. Calculate 14-day moving average and standard deviation 2. Determine boundaries: mean ± 2*stddev 3. Mark days outside boundaries as 'spike' or 'drop' 4. Output sale_date, daily_amount, moving_avg, lower_bound, upper_bound, anomaly_type **Hint:**
Sign in to solve
Start Solving