Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add uncertainty intervalls for predictions (CET/DERT/CLV) #170

Open
mmeierer opened this issue May 3, 2021 · 8 comments
Open

Add uncertainty intervalls for predictions (CET/DERT/CLV) #170

mmeierer opened this issue May 3, 2021 · 8 comments
Labels
enhancement New feature or request

Comments

@mmeierer
Copy link
Collaborator

mmeierer commented May 3, 2021

As a universal approach for all methods in CLVTools, implement a boostrapping procedure to be able to generate uncertainty intervalls for predictions (CET/DERT/CLV)

@mmeierer mmeierer added the enhancement New feature or request label May 3, 2021
@mmeierer mmeierer added this to To do in v0.9.1 via automation May 3, 2021
@mmeierer mmeierer removed this from To do in v0.9.1 May 3, 2021
@mmeierer mmeierer closed this as completed May 3, 2021
@mmeierer mmeierer reopened this May 7, 2021
@mmeierer mmeierer added this to To do in v0.9.1 via automation May 7, 2021
@mmeierer mmeierer changed the title Add reporting of confidence intervalls Add uncertainty intervalls for predictions (CET/DERT/CLV) May 7, 2021
@pschil pschil removed this from To do in v0.9.1 Jan 10, 2022
@tm185246
Copy link

Hello,

Wanted to check if this is implemented, specifically for the pnbd with dynamic covariates? I think this would be a highly useful feature, desirable for many different reasons.

Thanks,
Tom

@mmeierer
Copy link
Collaborator Author

This is not yet implemented.

Would you mind sharing your use cases? Depending on whether these use cases appeal to a broader audience, we might move this feature up on our priority list.

@tm185246
Copy link

I am implementing CLV predictions for a client and they have asked directly for confidence intervals for the predictions. The more (or less) confident we are about a certain prediction may influence how the client reaches out to a customer; they may choose to view a wider range for the prediction corresponding to a bigger opportunity for upselling. They also would like to have a confidence interval for how much revenue the customers will produce on aggregate over the next X years.

Hope that makes sense. Thanks!

@mmeierer
Copy link
Collaborator Author

Thanks. We might look into adding an implementation for boostrapping but this procedure is likely to be rather slow (as pointed out by previous literature). However, for a consultancy project that does not require to repeatly such an anlaysis it might be somewhat usable - depending on the size of your data.

@tm185246
Copy link

tm185246 commented Apr 17, 2023 via email

@tm185246
Copy link

Out of curiosity, would the way to bootstrap here be to resample from our cohorts with replacement, fit the model, store our predictions, and repeat many times? I'm guessing that we wouldn't have a production for each customer each time, but if we repeat many times we will end up with ample predictions for each customer anyway.

Or is there another way to bootstrap this?

@pschil
Copy link
Collaborator

pschil commented Apr 24, 2023

You should be able to get confidence intervals using bootstrapping.
Randomly selecting customers and all their respective transactions with replacement should be the way to go (and not randomly selecting transactions). From the many predicted CLV values of each customer you can then make 95% CI bounds for each customer.

You are right that with this approach you will not get predictions for every customer in each sample but it should even out if there are enough repetitions as some customers are also present more than once per sample.

@tm185246
Copy link

Awesome. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants