1
$\begingroup$

I work for a payments company and have been tasked with answering the following question: what is the likelihood that a customer connects a bank account after the customer's account has been created. The hypothesis is that for every day that passes from the date the account was created, the likelihood that they will connect a bank account decreases.

In this case, the birth/exposure event is the account creation date, and the death event is the date the bank account was connected. My data is right-censored (there are many customers who have not experienced the death event - connect a bank account - yet).

For each customer I have a column for the duration ('t') and whether the event was observed ('e'). For those where the event has not yet been observed, 'e' = 0.

In my dataset, the largest number of customers connect a bank account on the same day that the account was created. So for them 't' = 0. On no other day is the death event observed as often as it is on day 0.

For those that have not yet connected a bank account, the duration ('t') value is the number of days that have elapsed between the date their account was created and today. For some, this could be upwards of close to 10 years (3,000+ days).

Using lifelines, I produced a summary table and a plot.

table  = survival_table_from_events(df['t'], df['e'])

enter image description here

And the plot for the kmf.survival_function is below:

enter image description here

And here is the kmf.survival_function plot up to a duration of 100 days with the median_survival_time and the 25th percentile survival time plotted as well:

enter image description here

Looking at the '100 days' chart, the median survival time is 9 days and the 25th percentile survival time is 81 days.

So my ultimate question is how to interpret the plot in plain English.

  • If on day 0 the plot shows ~60% survival probability, does that mean after day 0, if they did not connect a bank account, there is a ~60% probability that a customer will connect a bank account at some future point? In other words, if they did not connect the bank account on the same day that there account was created, there is still a 60% probability that they will at some point?

  • If on day 9 the plot shows 50% survival probability, does that mean that after 9 days, if the customer has not yet connected a bank account, there is a 50% probability that they will do so at some future point?

  • If on day 81 the plot shows 25% survival probability, does that mean that after 81 days, if the customer has not yet connected a bank account, there is a 25% probability that they will do so at some future point?

Am I stating what I am seeing in the chart correctly? If not, what is the correct interpretation of those points on the plot?

$\endgroup$
2
  • $\begingroup$ Hi Jason, you say "The hypothesis is that for every day that passes from the date the account was created, the likelihood that they will connect a bank account decreases." This makes me think you should be considering the hazard rate (along with the survival plot). Check out the Nelson-Aalen estimator. $\endgroup$ Aug 21, 2023 at 22:34
  • $\begingroup$ I suggest the hazard rate because I think the question you are wanting to answer is really "is my hazard rate increasing or decreasing over time? Our hypothesis is that it is decreasing". A decreasing hazard rate process implies that the event becomes less likely over time. $\endgroup$ Aug 21, 2023 at 22:36

1 Answer 1

0
$\begingroup$

The KM estimator estimates the survival function, this means that it gives probabilities that an individual survives longer than a given value. In this case, that it would take longer than a given value for an individual to connect a bank account. Your question however differs from traditional survival models a bit in the sense that the event might never happen. This is modelled with a cure model. So the interpretation of the KM estimated survival probability as "the probability that they will create an account at some point in the future" will be an overestimation that could be quite large depending on the circumstances, see here.

This part: "The hypothesis is that for every day that passes from the date the account was created, the likelihood that they will connect a bank account decreases." sounds like you are not interested in the survival function, but rather in the hazard function. The hazard function $h(t)$ and survival function $S(t)$ are linked by the identity

$$h(t) = -\frac{d}{dt}log(S(t)) $$

Where the hazard gives a measure of the instantaneous risk of the event happening at any time point. So a possible approach would be to estimate the survival function with e.g. a mixture cure model, then transform the estimated survival to a hazard function and confirm whether it actually decreases over time.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.