4
$\begingroup$

I'm analyzing users' in-game data in order to model whether they're going to be paid user or not.

Here's my model:

Logistic Regression Model

lrm(formula = becomePaid ~ x1 + x2 + 
    x3 + x4 + x5 + x6, data = sn, x = TRUE, 
    y = TRUE)

                      Model Likelihood     Discrimination    Rank Discrim.    
                         Ratio Test            Indexes          Indexes       
Obs         1e+05    LR chi2    1488.63    R2       0.147    C       0.774    
 0          99065    d.f.             6    g        1.141    Dxy     0.547    
 1            935    Pr(> chi2) <0.0001    gr       3.130    gamma   0.586    
max |deriv| 8e-09                          gp       0.011    tau-a   0.010    
                                           Brier    0.009                     

               Coef    S.E.   Wald Z Pr(>|Z|)
Intercept      -6.7910 0.0938 -72.36 <0.0001 
x1              0.0756 0.0193   3.92 <0.0001 
x2              0.0698 0.0091   7.64 <0.0001 
x3              0.0020 0.0002  11.05 <0.0001 
x4              0.0172 0.0057   3.03 0.0024  
x5              0.0304 0.0045   6.82 <0.0001 
x6             -0.0132 0.0042  -3.17 0.0015  

And in my model, I created couple of use cases such as:

    test1   test2       
x1  8           9
x2  10          10
x3  250        250
x4  6           6
x5  2           2
x6  0           1

Then the probability of user test1 is to turn out to be a paid user is %.07 and % 0.84 for test2.

However I want to calculate the cumulative probabilities such as users whose' x1 values are greater than 8, x2 values are between 10 and 20 and so on.

Is there any way to calculate this ?

Thanks !

$\endgroup$
  • $\begingroup$ What do you mean with ‘cumulative probabilities’? What it could mean in this context is not clear to me. Can you elaborate on what you want know in plain English? $\endgroup$ – Gala Jul 24 '13 at 9:58
  • $\begingroup$ For example, I want to calculate the probability of being a paid user for users with these conditions: x1>10, x2>12, 300>x3>375, 4>x4>6, x5>2, x6=1. Since I can only calculate probability for exact conditions (like x1=8,x2=10,x3=250,x4=6,x5=2,x6=0) I don't know how to calculate ranges for numeric variables, that's why I said cumulative probabilities. $\endgroup$ – CanCeylan Jul 24 '13 at 10:08
  • $\begingroup$ Yes, but what do you think this number would tell you? Some of your conditions are open-ended, obviously your prediction for x1 = 10 could be very different than that for x1 = 500 or x1 = 330000. Which one are you interested in? How could a single number capture all that? Are you looking for some “average” or typical probability for all users matching these conditions? The minimum predicted probability? $\endgroup$ – Gala Jul 24 '13 at 10:22
  • $\begingroup$ My aim is, let's say x1 refers to a level of a user. Then I want to say that, with % X probability users with higher than level 10 will be a paid user. $\endgroup$ – CanCeylan Jul 24 '13 at 10:25
  • $\begingroup$ It is a good idea when estimating something to be able to interpret the estimate. What you propose does not have a good interpretation, being a function of all the x1 values in the sample. This is because of incomplete conditioning. $\endgroup$ – Frank Harrell Jul 24 '13 at 11:36
5
$\begingroup$

I will take the last example you gave in the comments as a focal point for the discussion. As you know, you can compute a predicted probability for a user with exactly level 10 (using reasonable values for the other predictors). You can also conclude that, according to your model, users with levels higher that 10 will have at least that probability to become paid users because the coefficient for $x_1$ is positive.

Among users with level 10 or higher, some will have exactly level 10 and in this case the probability you computed above is your best guess. Some will also have higher levels and therefore, if the model is correct, a higher probability to convert to paid user status. As a group, the proportion that you can expect to convert will depend on the distribution of $x_1$. If most have level 10, it would be lower than if there is a wide range of levels.

What the model is representing is the probability for a single user to become a paid user, given a particular set of characteristics. Each user meeting the conditions you specify will be assigned a different probability to convert by the model. That's why it's not so clear to me what you have in mind when you are talking about ‘cumulative probabilities’ or the probability for a ‘range’.

In practice, I would do this:

  • Compute a minimum or maximum probability if the conditions allow it (e.g. for $x_1 > a$ and $x_6 > b$ the minimum is 0 and the maximum 1, i.e. anything is formally possible because the two variables “push” in opposite directions). Report that in any case.
  • Calculate the mean or median values for each predictor using only the data matching the conditions and run that through the model. This could be interpreted as the prediction for a “typical” user in this range.
  • Calculate some high and low percentiles/possible scenarios for your predictors and discuss that. For example, say you know that among users above level 10, 50% have exactly level 10 and only 5% are above level 35. You compute a prediction for level 10 and level 35. You can then say that the probability of a given user converting is likely in-between and note that it corresponds to this and that level. You can also create some plots to illustrate these scenarios.
$\endgroup$
  • 2
    $\begingroup$ Related to that, I do routinely compute inter-quartile-range odds ratios (an automatic feature of the R rms package). $\endgroup$ – Frank Harrell Jul 24 '13 at 11:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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