Designing Evaluation Framework for Checkout Donation Feature
Statistics & ExperimentsModel answerLast updated
Design a metrics hierarchy, user-level experiment plan, and launch decision framework for an optional checkout donation feature on a food-delivery platform.
An online food-delivery platform is evaluating an optional checkout feature that allows customers to add a small donation (either directly to the merchant or to a charity selected by the merchant) when placing an order.
You are the lead Data Scientist assigned to design the evaluation framework. Write a comprehensive evaluation plan that covers the following five areas:
- Product Goal & Hypotheses: Define the main product objective. State one primary hypothesis and 2–4 secondary hypotheses (including at least one plausible negative effect).
- Metrics Hierarchy: Establish a structured framework with primary, diagnostic, and guardrail metrics. For critical metrics, specify the unit of analysis, numerator/denominator, evaluation window, and stage in the checkout funnel.
- Experimentation Strategy: Outline the experiment design:
- Randomization unit, triggering, and eligibility logic.
- Variant structure.
- Sample size, power, and duration considerations (including variance reduction techniques like CUPED).
- Strategies for handling repeated exposures, marketplace spillovers (courier/merchant equilibrium), novelty decay, and heterogeneous treatment effects.
- Risks & Confounders: Identify key biases and risks (e.g., selection bias, tip cannibalization, instrumentation bugs) and detail mitigation strategies.
- Launch Decision Framework: Define clear rules for launching the feature and how to make trade-off decisions across conflicting outcomes.
Hints
Hint 1
Distinguish between the unit of randomization (user) and the unit of analysis (order) when calculating standard errors for ratio metrics.
Hint 2
Consider marketplace feedback loops: reduced courier tips could impact order acceptance and fulfillment times for both treatment and control users.
Hint 3
Formulate checkout conversion rate as a non-inferiority hypothesis test rather than a standard two-tailed test.
Model answer
Easy Try it yourself first — then compare your approach, complexity and edge cases.
Evaluation Plan: Optional Checkout Donation Feature
1. Product Goal & Hypotheses
Product Goal
Provide users with an easy way to support local merchants or social causes during checkout, strengthening merchant relationships and user platform affinity without degrading core marketplace economics (order completion rates, gross merchandise value, or driver compensation).
Primary Hypothesis ($H_1$)
- $H_1$ (Checkout Non-Inferiority & Adoption): Introducing a donation module at checkout generates a meaningful donation attach rate while causing no more than a negligible, pre-defined reduction in checkout completion rate (non-inferiority margin $\delta \le 0.30$ percentage points).
Secondary Hypotheses
- $H_2$ (User Retention - Positive): Exposure to the donation option increases 28-day user re-order frequency via enhanced platform trust and emotional alignment ("warm glow" effect).
- $H_3$ (Merchant Retention - Positive): Participating merchants observe higher customer repeat rates and reduced platform churn over 30 days.
- $H_4$ (Tip Cannibalization - Negative): Users operate on a fixed total budget for discretionary order add-ons, leading them to decrease courier tips when adding a donation.
- $H_5$ (Checkout Friction - Negative): Additional screen elements increase cognitive load and time-to-order, resulting in higher cart abandonment on mobile devices.
2. Metrics Hierarchy
The table below outlines the core metrics spanning primary success, diagnostic mechanisms, and operational guardrails:
| Metric Type | Metric Name | Unit of Analysis | Mathematical Definition | Window | Funnel Stage |
|---|---|---|---|---|---|
| Primary | Donation Attach Rate | User (ratio) | $\frac{\text{Completed Orders with Donation > $0}}{\text{Total Completed Orders by Triggered Users}}$ | Experiment Window | Post-Checkout |
| Primary | Mean Donation per Triggered User | User | $\frac{\text{Sum of All Donation Dollars ($)}}{\text{Total Triggered Users Assigned}}$ | Experiment Window | Post-Checkout |
| Co-Primary / Non-Inferiority | Checkout Conversion Rate | User | $\frac{\text{Users with } \ge 1 \text{ Completed Order}}{\text{Users Reaching Checkout at Eligible Merchants}}$ | Session / User Aggregated | Checkout Screen $\rightarrow$ Order Completion |
| Diagnostic | Module Impression Rate | Session | $\frac{\text{Sessions Rendering Donation Module}}{\text{Total Checkout Sessions at Eligible Merchants}}$ | Real-Time | Checkout Screen |
| Diagnostic | Checkout Dwell Time | Session | Median duration (seconds) spent on checkout screen | Per Session | Checkout Screen |
| Diagnostic | Option Selection Share | Order | $\frac{\text{Donations via Presets ($1, $2, Round-up)}}{\text{Total Donation Count}}$ | Experiment Window | Post-Checkout |
| Guardrail | Driver Tip Rate & Tip Amount | Order / User | $\frac{\text{Orders with Tip > $0}}{\text{Total Orders}}$ and $\frac{\text{Total Tip ($)}}{\text{Total Orders}}$ | Per Order | Post-Delivery |
| Guardrail | Order Frequency & Non-Donation Spend | User | Count of completed orders and net order spend (excluding donation) per user | 28 Days Post-Exposure | Full Funnel |
| Guardrail | Delivery Latency & Acceptance Rate | Order | Dispatch-to-delivery duration; % of orders accepted on first driver assignment | Real-Time / Daily | Fulfillment |
| Guardrail | Technical Error & Latency Rates | Request | p95 checkout rendering latency; % failed payment requests | Real-Time | Checkout Screen |
Variance Estimation for Order-Level Ratios
Because individual users place multiple orders during the test window, order-level metrics (such as attach rate or tip amount per order) suffer from intra-user correlation. Standard errors for these ratio metrics must be adjusted using the Delta Method applied to user-aggregated quantities or via a User-Cluster Bootstrap to prevent artificially narrow confidence intervals and elevated false positive rates.
3. Experimentation Strategy
3.1 Unit of Randomization & Eligibility
- Randomization Unit: User level. Randomizing by user guarantees a consistent experience across repeat orders, avoids user confusion, and allows long-term retention measurement ($H_2$).
- Eligibility: Users entering the checkout flow for an eligible merchant (a merchant that has opted in or selected an approved charity).
- Intent-to-Treat (ITT): Experiment entry occurs when an assigned user reaches the checkout screen of an eligible merchant. Control group users trigger a counterfactual log event at the exact same point to ensure balanced triggers across arms.
3.2 Variant Design
- Control ($C$): Existing checkout flow (no donation option displayed).
- Treatment 1 ($T_1$): Checkout with donation module containing a custom amount input field only.
- Treatment 2 ($T_2$): Checkout with donation module including quick-select buttons (e.g., Round-Up, $1.00, $2.00).
Comparing $T_1$ against $T_2$ isolates whether pre-set prompt amounts drive incremental donations or introduce unwanted screen clutter.
3.3 Sample Size, Power, and Variance Reduction
- Sample Size Determination: The checkout conversion rate (baseline $p \approx 70%$) dictates the required sample size under a non-inferiority framework ($\delta = 0.30%$, $\alpha = 0.05$, $\beta = 0.20$). $$\text{Sample size per variant} \approx \frac{2 \cdot (Z_{\alpha} + Z_{\beta})^2 \cdot p(1-p)}{\delta^2} \approx 370,000 \text{ triggered users per arm}$$
- Variance Reduction (CUPED): Apply Controlled-experiment Using Pre-Experiment Data (CUPED) on continuous primary metrics (user conversion and spend) using pre-period order count and spend from the prior 30 days as covariates. This routinely reduces metric variance by 20–35%, reducing the required sample size or runtime.
- Duration: Run the test for 4 full weeks to capture recurring weekly purchasing patterns, give initial novelty effects time to wear off, and collect a complete 28-day post-exposure window for user retention tracking.
3.4 Novelty Effects, Marketplace Spillovers, and Heterogeneity
- Novelty Decay: Measure daily treatment effects indexed by elapsed days since a user's initial exposure. Evaluate launch criteria on data from weeks 3 and 4 rather than early impression spikes.
- Marketplace Interference:
- Merchant Spillover: Treated and control orders share the same merchants. Merchants receiving high donation volume might change pricing or fulfillment behavior, affecting both arms.
- Courier Spillover: If treated users lower tip amounts, drivers in the region might reject orders more frequently, degrading fulfillment metrics across both arms in that city.
- Mitigation: Conduct a post-launch Geo-Cluster or synthetic control holdout test across matched metropolitan areas to measure market-level equilibrium effects.
- Heterogeneous Treatment Effects (HTE): Pre-register subgroup evaluations across:
- Order Frequency: Heavy vs. casual users.
- Basket Size: Small individual orders ($<$15$) vs. large group orders ($>$50$).
- Merchant Category: National enterprise chains vs. local independent restaurants.
4. Risks, Biases, and Confounders
| Risk / Bias | Impact on Evaluation | Mitigation Strategy |
|---|---|---|
| Merchant Selection Bias | Merchants choosing to participate may have higher baseline customer loyalty, making donation performance look better than average. | Restrict evaluation to users placing orders at participating merchants. Avoid extrapolating results to non-participating merchants. |
| Observational Conditioning Bias | Comparing users who donated to those who did not introduces severe self-selection bias (donors are inherently higher-intent customers). | Analyze all outcomes strictly under Intent-to-Treat (ITT) across assigned variants; avoid observational comparisons of donors vs. non-donors. |
| Tip Cannibalization | Added donation prompts reduce courier tip rates, degrading driver satisfaction and order acceptance times. | Set driver tip rate and tip amount as blocking guardrail metrics; monitor total add-on spend (tip + donation) per order. |
| Equilibrium Effects | Market-wide driver tipping shifts impact fulfillment speeds for both treatment and control arms in an A/B test. | Pair user-level A/B testing with a regional geo-holdout test post-launch to isolate cross-arm spillover. |
| Instrumentation Errors | Module rendering failures or missing tracking triggers skew treatment group measurements. | Run A/A validation tests prior to launch; log counterfactual impression triggers in the control group; run daily Sample Ratio Mismatch (SRM) checks. |
5. Launch Decision Framework
Standard Launch Thresholds
Launch Treatment $T^*$ if all of the following conditions are satisfied:
- Checkout Non-Inferiority Met: The lower bound of the 95% confidence interval for the treatment impact on checkout conversion rate is above $-\delta$ (where $\delta = 0.30%$).
- Statistically Significant Adoption: Donation attach rate is significantly greater than $0%$ ($p < 0.01$).
- Guardrails Intact:
- Courier tip rate and tip amount do not show a statistically significant decline ($p \ge 0.05$).
- 28-day user order frequency and non-donation GMV show no statistically significant drop.
- Technical and operational latency metrics (p95 checkout latency, payment error rates, order delivery times) remain within standard operational tolerance limits.
Trade-Off Decision Matrix
CHECKOUT CONVERSION
Non-Inferior Statistically
(Within -0.30% Margin) Degraded (<-0.30%)
+-----------------------+-----------------------+
COURIER TIPS | | |
Intact / | 1. FULL LAUNCH | 2. NO LAUNCH |
No Drop | | (Redesign UI) |
+-----------------------+-----------------------+
COURIER TIPS | | |
Statistically | 3. CONDITIONAL | 4. NO LAUNCH |
Reduced | HOLDOUT | (Feature Scrapped) |
+-----------------------+-----------------------+
- Full Launch (Cell 1): Both primary non-inferiority and guardrails hold. Proceed to rollout.
- No Launch / UI Friction (Cell 2): Conversion drops beyond the non-inferiority margin despite tips remaining unchanged. Redesign the checkout module to minimize layout friction (e.g., test collapsed accordion menus or post-checkout placement).
- Conditional Holdout / Cannibalization Risk (Cell 3): Conversion holds, but driver tips drop significantly. Do not launch globally. Run a 4-week market-level geo-holdout test to determine whether tip reductions cause driver churn or fulfillment delays. If tipping shifts persist, evaluate adjusting default tip suggestions upwards or moving donations entirely to a post-delivery screen.
- No Launch / Critical Failure (Cell 4): Feature harms both conversion and courier earnings. Reject deployment.