KatInterview

Design an Experiment for a Marketplace Convenience Feature

Statistics & ExperimentsModel answer
MediumModel answerStatistics & Experimentsexperimentationcausal-inferencemarketplace

Last updated

Plan and evaluate a controlled test for a new guest amenity in a two-sided platform, covering unit choice, metrics, power, and interference risks.

You work as a data scientist at a two-sided marketplace platform. The product team wants to test a new convenience amenity that allows guests to drop off their belongings at a secure storage facility near their accommodation before the official check-in window opens. This way, travelers arriving early can explore the area without carrying their bags.

Your job is to design the experiment that will determine whether the platform should roll out this feature broadly.

The question has two components: experimental design (Parts 1–5, 7) and hands-on test execution (Part 6).


Background & Constraints

  • The platform is a two-sided marketplace: changes affect guests, hosts, and platform economics. These interests don't always align.
  • Storage facilities have limited capacity in each geographic area and may be shared across multiple bookings.
  • Relevant outcomes appear across the entire trip lifecycle: some (like booking conversion) occur early, while others (ratings, support issues, damage disputes) only materialize days after checkout.
  • Use standard hypothesis testing conventions unless you have strong justification otherwise: $\alpha = 0.05$ (two-sided), 80% power.
  • Historical data on baseline metrics (support contact rates, conversion rates, etc.) is available for sample-size calculations.

Clarifying Questions You Should Consider

  • Does the feature appear pre-booking (influencing search and conversion) or post-booking (improving the stay experience)? This shifts both the primary metric and the assignment timing.
  • Is storage listing-specific (managed by individual hosts) or shared infrastructure (centralized facilities serving a neighborhood)? This determines whether interference between units is plausible.
  • What's the rollout plan — a UI toggle, host opt-in, or city-by-city launch? The experiment should match the real deployment mechanism.
  • Is the service complimentary or paid? Pricing affects both the metric suite and the revenue equation.
  • What minimum detectable effect would make launch worthwhile given implementation costs?
  • Are there liability or insurance concerns (lost or damaged items) that could block launch even if metrics look positive?

Part 1: Randomization Unit

What should be the unit of randomization: guest account, reservation, host/listing, or geographic market? Justify your answer and explain how the decision depends on the feature's implementation details.

What to address:

  • Go beyond defaults ("always randomize users") and reason from interference and SUTVA.
  • Identify contamination channels (shared capacity, host behavior shifts) and which unit choice contains them.
  • Discuss the power vs. validity tradeoff: smaller units give more power but may violate independence assumptions.

Part 2: Population and Treatment Definition

Define the eligible population, treatment condition, and control condition with enough precision that an engineer could implement the assignment logic.

What to address:

  • Eligibility must be determined before assignment and not depend on post-randomization actions.
  • Treatment is the opportunity to use the amenity, not actual usage.
  • Control reflects the current realistic alternative, not an artificially degraded experience.

Part 3: Metric Selection

Select a primary metric, a set of secondary metrics, and guardrails. Discuss tradeoffs across guest satisfaction, host satisfaction, operational expenses, safety, and platform revenue.

What to address:

  • Justify a single primary metric based on where the feature sits in the user journey.
  • Organize metrics hierarchically (primary / secondary / guardrail), not as a flat list of everything measurable.
  • Explicitly acknowledge marketplace tensions — name the guardrails protecting hosts, safety, and costs, and state a launch decision framework.

Part 4: Sample Size and Duration

Explain how you'd calculate the required sample size and determine the test duration.

What to address:

  • Compute sample size from a pre-specified minimum detectable effect using the appropriate power formula for your primary metric type.
  • Account for design effect inflation if randomizing at a clustered level, with intuition about intra-cluster correlation.
  • Duration reasoning beyond simple arithmetic: weekly patterns, the lag between assignment and outcome maturation, and thin-traffic markets.

Part 5: Analysis Methodology

Describe how you would estimate the treatment effect and compute statistical significance for the primary metric, including variance reduction and handling of clustered designs.

What to address:

  • Explicitly state the intention-to-treat estimand and never condition on post-assignment usage.
  • Match the statistical test to the metric type and report confidence intervals and effect sizes, not just p-values.
  • Discuss variance reduction techniques (covariate adjustment, CUPED) and cluster-robust inference when relevant.

Part 6: Hands-On Test Execution

You receive a reservation-level experiment dataset with these columns:

ColumnTypeDescription
unit_idstringRandomization unit identifier
guest_id, host_id, listing_idstringParticipant identifiers
marketstringGeographic market
assignment_variantstringtreatment or control
assigned_attimestampAssignment timestamp (UTC)
checkin_at, checkout_attimestampStay dates
bookedint1 if booking completed
used_lockerint1 if guest used the amenity
support_contactedint1 if guest contacted support
post_stay_ratingfloatGuest rating after checkout
gross_booking_valuefloatBooking revenue
pre_assignment_tripsintHistorical trip count (pre-period)
pre_assignment_support_ratefloatHistorical support rate (pre-period)
is_aa_testboolTRUE for A/A holdout rows

Explain concretely how you would:

  1. Run the A/B test to estimate the effect and compute a p-value using this table
  2. Run an A/A test to detect bias, sample ratio mismatch, or instrumentation problems

Reference specific columns in your answer.

What to address:

  • A column-specific, executable A/B procedure: filtering, validation checks, and ITT estimation on your chosen primary.
  • Treat used_locker as post-treatment only — a diagnostic, never a filter for the main analysis.
  • An A/A that includes sample ratio mismatch testing (chi-square) and covariate balance checks (standardized mean differences), with interpretation of failures.

Part 7: Risk Assessment

Identify risks specific to this experiment: selection bias, interference between arms, capacity constraints, host-side spillovers, and heterogeneous treatment effects across markets. For each, explain how your design or analysis addresses it.

What to address:

  • A risk-mitigation mapping: pair each risk with the specific design choice or analysis technique that addresses it.
  • Show that mitigations are the same levers chosen earlier (unit selection, ITT, stratification), demonstrating design coherence.
  • Address heterogeneity discipline — pre-specified subgroup analyses, not post-hoc data mining.

Hints

Hint 1

Consider how shared infrastructure creates dependencies between seemingly independent units

Hint 2

The booking-to-outcome timeline spans weeks; your test duration must account for this maturation lag

Hint 3

Intent-to-treat preserves randomization; conditioning on actual usage introduces post-treatment bias