Last answered:

13 May 2021

Posted on:

14 Apr 2021


Resolved: Are there 2 different frameworks for similar problems?

Hi there!

Going straight to the point. Problem: Fitting logistic regression models BY SEGMENTS.

Framework 1:
When modeling Purchase Incidence: Purchase Probability by Segments:
the lecture tells us we should fit 4 different models and obtain 4 different coefficients, one for each segment, based on the features ONLY from the records of the corresponding segment. Then use each parcticular calculated coefficient from the segment to calculate elasticities.
When in the lecture is obtained the coefficient for segment 1, it literally says "It's -1.7, so it's lower in absolute terms compared to the average consumers coefficient (-2.34). Therefore it will have a lower impact when we calculate elasticities."

Framework 2:
When modeling Brand Choice: Own and Cross-Price Elasticity by segments:
the lecture tells us we should fit the model and calculate the coefficients based on the features from ALL the records disregarding the segment, for the average customer. Then use the one and only coefficient obtained for the average customer to calculate elasticities at all the 4 segments.
Note: Despite in the lecture are calculated the coefficients for each segment, they are not used. I already got confused about this and asked you previously, and you told me "The reason why we originally included the table (the coefficients for each segment) is to be able to track some dependencies between brand coefficients and price, based on the specific segments. However, they are not included in the computation of the Price Elasticity curve as the coefficients there are based on the brand only."

I thought it was clear to me, but suddenly I realized we have 2 different ways to procced under the same general scenario: Fitting a logistic regression model for each specific segment and select and apply its coefficients poperly to calculate elasticities.
I have some specific questions I need to resolve, all of them:

- Must the coefficients for both scenarios be calculated and applied under the same methodology? If not, why not? what would be the difference between both scenarios?

- If in your answer of my previous post you told me that for modeling Brand Choice by Segments "they (the coefficients for each segment) are not included in the computation of the Price Elasticity curve as the coefficients there are based on the brand only", why this same issue does not apply when modeling Purchase Incidence by Segments? Does the coefficients for modeling Purchase Incidence by Segments are NOT based only on the brand as well? If each case is different... why?

Once againt, thank you so much for your time, and I just have to say I'm really interested in the course and that's why I want to have it all crystal clear.


2 answers ( 1 marked as helpful)
Posted on:

23 Apr 2021


Hi Jesus,
thanks for reaching out! To your question, there is a difference between the two formulas. In the first case we're calculating price elasticty of puchase probability. In the second, we're calculating price elasticity of brand choice - therefore we're looking at different formulas here. In the first case, we're interested to find out whether our clients are going to buy a chocolate candy bar, - yes or no. In the second case, we're looking at which brand they're going to choose, here we assume they are going to purchase something.
I've added the derivation notes for the different formulas, in case you want to look at them in more detail:
Customer Analytics in Python | 365 DataScience
I understand this is a complex and broad topic. We've tried to give a comprehensive overview(as much as it is possible to do in a 5 hours course). However, delving into the topic of customer analytics and understanding all the details and nuances requires a lot of time and dedication, and it's only natural that some things will be unclear at the start.
So, if you have any other questions on the topic, I'll try and answer them as best I can.

365 Eli

Posted on:

13 May 2021


Thank you so much again, Eli. I´ll do my best to try to understand. Thanks for your patience.


Submit an answer