← All data exercises

Define churn from daily account equity and predict which investors will leave

2 tables · 1.1M rowsUnlock with Pass

Fernway Invest is a commission-free investing app. To improve retention, its growth team wants to understand why users withdraw their money and which users are likely to do so.

The team considers a user churned when their equity value (the amount of money in their Fernway account) falls below $10 for a period of 28 consecutive calendar days or longer.

The data

  • user_features — one row per user, mostly what they reported when they opened the account:
    • risk_tolerance, investment_experience, liquidity_needs, time_horizon: self-reported by the user.
    • platform: iOS or Android.
    • time_spent: amount of time spent in the app.
    • first_deposit_amount: dollar value of the user’s first deposit.
    • instrument_type_first_traded: the type of instrument the user traded first.
  • equity_values — one row per user per day on which the user’s equity was $10 or more: timestamp (UTC) and close_equity, the account’s equity value in dollars at the close. Days on which equity was below $10 have no row, so churn has to be read from the gaps.

Your task

  1. Turn the churn definition into a precise rule you can apply to equity_values, and use it to label every user. Decide and justify how you treat:

    • days with no row that may not mean equity below $10 (check which days of the week and year appear at all);
    • users whose records stop less than 28 days before the end of the data;
    • users who meet the definition and later come back.

    What share of users churned, and how much does that figure move under the reasonable alternatives you considered?

  2. Before modeling, explore how churned and retained users differ. Which differences look meaningful, and which could be artefacts of how a field was measured? Say when each feature is known (at sign-up, or accumulated over time like time_spent) and whether it would be available at the moment the team wants to predict churn.

  3. Build a classifier that assigns every user a churn probability, and classify each user as churned or not. Explain your choice of model, how you validated it, which metrics you report given how common churn is, and how you chose the classification threshold.

  4. Which features matter most for churn, and how confident are you in that ranking? Separate what the model finds predictive from what you would expect to cause churn, and say how the growth team could tell the two apart.

  5. How should the growth team use the scores? Propose one or two interventions, who they would target, what they would cost if aimed at the wrong users, and how you would test whether they reduce churn. What other data would most improve the model?

What to deliver

A short report for the growth team: your churn definition and its checks, the model and how well it works, the main drivers, and your recommendations. Include a table of churn probabilities and predicted labels keyed by user_id, and an appendix with the queries or code behind each number.

All company names in this question are fictional.

Data preview

equity_valuesfirst 5 rows
timestampclose_equityuser_id
2016-11-15 16:00:00-08:0048.16bcef4fa9b0bdf22bcf7deae708decf03
2016-11-16 16:00:00-08:0048.16bcef4fa9b0bdf22bcf7deae708decf03
2016-11-17 16:00:00-08:0048.16bcef4fa9b0bdf22bcf7deae708decf03
2016-11-20 16:00:00-08:0048.16bcef4fa9b0bdf22bcf7deae708decf03
2016-11-21 16:00:00-08:0048.16bcef4fa9b0bdf22bcf7deae708decf03
user_featuresfirst 5 rows
risk_toleranceinvestment_experienceliquidity_needsplatformtime_spentinstrument_type_first_tradedfirst_deposit_amounttime_horizonuser_id
high_risk_tolerancelimited_investment_expvery_important_liq_needAndroid33.1294stock40med_time_horizon895044c23edc821881e87da749c01034
med_risk_tolerancelimited_investment_expvery_important_liq_needAndroid16.5735stock200short_time_horizon458b1d95441ced242949deefe8e4b638
med_risk_tolerancelimited_investment_expvery_important_liq_neediOS10.0084stock25long_time_horizonc7936f653d293479e034865db9bb932f
med_risk_tolerancelimited_investment_expvery_important_liq_needAndroid1.0316stock100short_time_horizonb255d4bd6c9ba194d3a350b3e76c6393
high_risk_tolerancelimited_investment_expvery_important_liq_needAndroid8.1873stock20long_time_horizon4a168225e89375b8de605cbc0977ae91