Important: Read this before posting to this forum

  1. This forum is for questions related to the use of Apollo. We will answer some general choice modelling questions too, where appropriate, and time permitting. We cannot answer questions about how to estimate choice models with other software packages.
  2. There is a very detailed manual for Apollo available at http://www.ApolloChoiceModelling.com/manual.html. This contains detailed descriptions of the various Apollo functions, and numerous examples are available at http://www.ApolloChoiceModelling.com/examples.html.
  3. Before asking a question on the forum, users are kindly requested to follow these steps:
    1. Check that the same issue has not already been addressed in the forum - there is a search tool.
    2. Ensure that the correct syntax has been used. For any function, detailed instructions are available directly in Apollo, e.g. by using ?apollo_mnl for apollo_mnl
    3. Check the frequently asked questions section on the Apollo website, which discusses some common issues/failures. Please see http://www.apollochoicemodelling.com/faq.html
    4. Make sure that R is using the latest official release of Apollo.
  4. If the above steps do not resolve the issue, then users should follow these steps when posting a question:
    1. provide full details on the issue, including the entire code and output, including any error messages
    2. posts will not immediately appear on the forum, but will be checked by a moderator first. This may take a day or two at busy times. There is no need to submit the post multiple times.

Predicted Probability Plots from ICLV Model

Ask questions about post-estimation functions (e.g. prediction, conditionals, etc) or other processing of results.
Post Reply
hossain
Posts: 11
Joined: 09 Apr 2021, 05:22

Predicted Probability Plots from ICLV Model

Post by hossain » 14 Apr 2021, 02:47

Dear Everyone,

Hope this post finds you well. I have a query regarding producing predicted probability plots. Is it possible to produce a predicted probability plot for a predictor (keeping all other predictors to the mean) from an ICLV model in apollo? Is there any code example for producing predicted probability plots from an ICLV model? Thank you!

stephanehess
Site Admin
Posts: 558
Joined: 24 Apr 2020, 16:29

Re: Predicted Probability Plots from ICLV Model

Post by stephanehess » 14 Apr 2021, 16:18

Hi

can you please be more specific with your query. Do you mean looking at the impact on probabilities of a change in one of the explanatory variables? If so, you can just use apollo_prediction after estimation and change the attribute in the database, and revalidate the inputs. It's not really different from what we do in Apollo_example_3.r

Stephane
--------------------------------
Stephane Hess
www.stephanehess.me.uk

hossain
Posts: 11
Joined: 09 Apr 2021, 05:22

Re: Predicted Probability Plots from ICLV Model

Post by hossain » 14 Apr 2021, 20:05

Hi Dr. Hess,

Thank you for your kind reply. I appreciate it. Here is a simple example for demonstrating the issue.

V = list()
V[['no']] = 0
V[['yes']] = asc_yes + b_student*student+b_age* age +b_education*education_college+ b_income_L*income_low

### Define settings for MNL model component
mnl_settings = list(
alternatives = c(no=0, yes=1),
avail = 1,
choiceVar = Use,
V = V)

Here, if we have a binary choice of "yes" and "no" whether someone used a service or not. After estimating the coefficient of the model, if I get a coefficient of -0.24 for income_low indicating low income are less likely to use compared to not low-income individual. Now, I want to know how much less likely. So, I want to produce an effect plot of predicted probabilities of "yes" for both low-income and not low-income (keeping all the other predictors to their mean value). For logistics regression, there are options like "effects" package by Fox, et al. Is there any option I can do this type of plot with my ICLV model output from the apollo. Thank you!

stephanehess
Site Admin
Posts: 558
Joined: 24 Apr 2020, 16:29

Re: Predicted Probability Plots from ICLV Model

Post by stephanehess » 15 Apr 2021, 12:14

Hi

yes, this is what you can do with apollo_prediction and changing the data. Please have a look at example_3 which does this for an MNL model and changes an attribute. The process is the same

Stephane
--------------------------------
Stephane Hess
www.stephanehess.me.uk

hossain
Posts: 11
Joined: 09 Apr 2021, 05:22

Re: Predicted Probability Plots from ICLV Model

Post by hossain » 16 Apr 2021, 01:59

Hi Dr. Hess,

Thank you! I appreciate it.

Post Reply