Ravindra BagaleCourses & study guides मराठी Track your progress

30. Statistics for Analysts

Practice and Answer Key: Describe, Correlate, Predict and Test a Kolhapur Store

Goal of this practice: Describe a column, measure a correlation, fit and use a regression line, and run a t-test, checking every number with a formula.

Suppose Rani manages a Kolhapur dark store. She has 10 days of discount and orders in A1:C11 (Day, Discount %, Orders) and delivery minutes for 8 morning and 8 evening orders in E1:F9 (Morning, Evening). All data is fictional practice data.

Day Discount % Orders
1 0 210
2 5 228
3 5 235
4 10 251
5 10 246
6 15 270
7 15 262
8 20 289
9 20 281
10 25 300
Morning Mins Evening Mins
11 15
13 13
12 17
10 14
14 16
12 18
11 13
13 15

Exercise (one under the other):

  1. Calculate the mean, median and sample standard deviation of Orders.
  2. Calculate the correlation between Discount and Orders and describe it in words.
  3. Fit a line with SLOPE and INTERCEPT and predict orders at a 12% discount.
  4. What share of the variation in orders does the line explain (R²)?
  5. Are evening deliveries slower than morning ones? Use T.TEST (two-tailed, type 3) at 5%.
  6. Write a two-sentence summary for Rani's manager.

Expected result (check your numbers):

Check Expected
Mean / Median of Orders 257.2 / 256.5
STDEV.S of Orders 28.5455
CORREL(Discount, Orders) 0.9921
SLOPE / INTERCEPT 3.5822 / 212.4222
Prediction at 12% 255.41
R² 0.9843
Mean Morning / Evening 12 / 15.125
T.TEST p-value 0.0017
Answer key (open after you try)
  1. =AVERAGE(C2:C11) = 257.2, =MEDIAN(C2:C11) = 256.5, =STDEV.S(C2:C11) = 28.5455.
  2. =CORREL(B2:B11,C2:C11) = 0.9921: a very strong positive correlation. Higher discounts went with more orders.
  3. =SLOPE(C2:C11,B2:B11) = 3.5822 orders per discount point, =INTERCEPT(C2:C11,B2:B11) = 212.4222. Prediction: =FORECAST.LINEAR(12,C2:C11,B2:B11) = 255.41, about 255 orders.
  4. =RSQ(C2:C11,B2:B11) = 0.9843, so about 98% of the day-to-day variation.
  5. =T.TEST(E2:E9,F2:F9,2,3) = 0.0017, below 0.05. Evening deliveries took 3.125 minutes longer on average, and the difference is statistically significant.
  6. For example: "Each extra discount point went with about 3.6 more orders over these 10 days (R² 0.98); this shows association, not proof that discounts caused all of it. Evening deliveries are about 3.125 minutes slower than morning ones (p = 0.002)."

Common mistakes:

What you see Why Fix
SLOPE gives a strange value x and y swapped: =SLOPE(B2:B11,C2:C11) y first: =SLOPE(C2:C11,B2:B11)
T.TEST p looks too small Type 1 (paired) used for two separate groups Use type 3
Standard deviation slightly different from the key STDEV.P instead of STDEV.S Use STDEV.S for a sample
"Discount causes orders" in the summary Correlation read as cause Say "went with"; other factors may matter

Ravindra Bagale's rule: a number without its spread, its range or its p-value is only half an answer.

Quick recap

  • Describe with centre, spread and shape; prefer the median and the 90th percentile for skewed data; STDEV.S for samples.
  • The ToolPak (desktop only) gives standard reports; its output is static, so check key lines with formulas.
  • Histograms and IQR fences show the shape and the outliers; an outlier is a question, not an error.
  • CORREL measures straight-line links; always look for a third factor before saying "causes".
  • LINEST returns several coefficients in reverse order; read regression output as Significance F, Adjusted R Square, then P-values and 95% ranges.
  • Report A/B tests as difference, 95% range and p-value; use CHISQ.TEST for counts; "not significant" means "not proven yet".

Loading practice tasks...

  1. Mean orders (Easy): Average of C2:C11.
  2. Median basket (Easy): Median of D2:D11.
  3. SD of visitors (Easy): Sample SD of B2:B11, rounded to 1 decimal.
  4. Visitors vs orders (Medium): Correlation of B2:B11 and C2:C11, rounded to 3 decimals.
  5. Orders per visitor (Medium): Slope of C2:C11 on B2:B11, rounded to 4 decimals.
  6. Predict 450 visitors (Medium): Predicted orders for 450 visitors, rounded to 0 decimals.
  7. Promo average orders (Medium): Average orders where Promo is "Yes".
  8. Promo vs no-promo basket gap (Hard): Average basket with "Yes" minus with "No", rounded to 1 decimal.
  9. Conversion rate (Hard): Total orders ÷ total visitors, rounded to 4 decimals.
  10. Weekend z-score (Hard): Z-score of B7 with the mean and sample SD of B2:B11, rounded to 2 decimals.