Ibotta / mr_uplift

Multiple Response Uplift (or heterogeneous treatment effects) package that builds and evaluates tradeoffs with multiple treatments and multiple responses
Apache License 2.0
64 stars 13 forks source link

Examples for multiple treatments #46

Closed yolimonsta closed 2 years ago

yolimonsta commented 2 years ago

Hi!

It is really exciting to see there is a package for multiple treatment uplift models. Wonder would it be possible to add an example for the multiple treatments model.

I found this 'This means that a user can input an arbitrary number of treatments (not just the usual binary variable) into the model' in your blog plots, but I am not so sure what kind of input is expected. For the multiple treatments, does it only allow the number of treatments or does it also allow a series of binary features?

Best, Yolanda

samcarlos commented 2 years ago

Hey Yolanda,

Thanks for your question. Basically you can include any numbers of treatments and encode them any way you'd like as long as they're numeric.

For instance in this blog post I have a list of treatments encoded:

[[0.0,0.0,0.0,0.0], [1.0,0.0,0.0,0.0], [1.0,1.0,0.0,0.0], [1.0,1.0,1.0,0.0]]

Each row is a treatment and each column is a feature that some treatments have in common. Also note that these can be real numbers not just ones and zeros.

If you have list of unique treatments the treatments list could be a dummied-out matrix.

Does that answer your question?

Thanks, Sam

yolimonsta commented 2 years ago

Thanks for sharing that! It is very helpful. For the multiple treatment models, are you implementing the algorithms from Uplift Modeling with Multiple Treatments and General Response Types?

Thanks! Yolanda

samcarlos commented 2 years ago

Hey Yolanda,

I use the same out-of-sample metric they use in that paper in section 2.2. However, I use a neural network and custom loss function to estimate the model. You can find more information about that here.

Thanks, Sam

yolimonsta commented 2 years ago

Thanks for the reply! It is very helpful.

Thanks, Yolanda

samcarlos commented 2 years ago

Hey Yolanda,

Can I close the issue?

Thanks, Sam

yolimonsta commented 2 years ago

Yes please!

Thanks a lot. Yolanda On Tue, 1 Feb 2022 at 18:22, Samuel Weiss @.***> wrote:

Hey Yolanda,

Can I close the issue?

Thanks, Sam

— Reply to this email directly, view it on GitHub https://github.com/Ibotta/mr_uplift/issues/46#issuecomment-1027427358, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANZDJ32P7GRDZZVKMPGNXI3UZB2LNANCNFSM5MIDHQFQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you authored the thread.Message ID: @.***>