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. In addition, help files are available for all functions, using e.g. ?apollo_mnl
  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.

estimation in WTP-space

Ask questions about errors you encouunter. Please make sure to include full details about your model specifications, and ideally your model file.
maa033
Posts: 35
Joined: 23 Jul 2020, 14:00

Re: estimation in WTP-space

Post by maa033 »

Just a quick follow-up question on the interpretation of the log-normally Distributed cost parameter; what does the delta-Method output tell? It tells that the actual cost parameter is approximately zero (as shown in the output script), but the very high Rob t-ratio provided by the deltMethod - what does that mean?
stephanehess
Site Admin
Posts: 974
Joined: 24 Apr 2020, 16:29

Re: estimation in WTP-space

Post by stephanehess »

I wouldn't really look at the t-ratio in that case. It's clear that the original parameter is not well estimated, see the NaN for the classical standard error for cost_sig. But your cost coefficient here is clearly not different from zero
--------------------------------
Stephane Hess
www.stephanehess.me.uk
MPFMAS001
Posts: 9
Joined: 16 Dec 2021, 09:05

Re: estimation in WTP-space

Post by MPFMAS001 »

stephanehess wrote: 18 Aug 2020, 10:37 Hi

there could be many reasons for this, and it's difficult to diagnose without seeing your outputs, and also how they compare to the model with Normals. A Normal distribution for cost of course makes no sense, so you're right to try negative Lognormals. One thing to consider is whether your starting values for the negative Lognormal are appropriate. I would advise starting cost_B_mu at something like -3 or even -5

Best wishes

Stephane
Hi Stephane,

Following this discussion, would you recommend specifying vtts and b_cost using different distributions for time and cost in the WTP space.

For example, suppose I specify betta_fare as negative log-normal and vtts as normal,

Assuming the utility to be additive, Is it correct to specify the utility function for alternative 1 as,
V[["alt1"]] =... + betta_fare(vtts * TT_1 + cost_1)
stephanehess
Site Admin
Posts: 974
Joined: 24 Apr 2020, 16:29

Re: estimation in WTP-space

Post by stephanehess »

Hi

to me, Normal does not make sense for VTT - see for example https://doi.org/10.1016/j.tra.2004.09.007 and https://doi.org/10.1016/j.trb.2016.11.002

But if you use two lognormals, then there is no need for wtp space as the results in preference space will be the same



Stephane
--------------------------------
Stephane Hess
www.stephanehess.me.uk
MPFMAS001
Posts: 9
Joined: 16 Dec 2021, 09:05

Re: estimation in WTP-space

Post by MPFMAS001 »

Thanks and happy holidays.

Regards

Masimba
MPFMAS001
Posts: 9
Joined: 16 Dec 2021, 09:05

Re: estimation in WTP-space

Post by MPFMAS001 »

Good day, David and Stephane,

I hope you're all doing well.

I am estimating a mixed logit for a public transport mode choice study with 3-time components, fare, and seating arrangement as variables. Like you advised the last time regarding how it doesn't make sense to assume Normal distribution for fare and time components, I tried to specify as lognormal and log uniform distribution and my LL keeps getting worse as I increase the number of draws, which would mean that I am estimating the wrong model. However, normal & uniform specifications seem to work just fine in that context, and my estimates for the fare:

Normal distribution
mean = -0.11153 (-13.32228)
sigma = 0.06084 (12.3186)
  • 3.3% non-zero probability of positive coefficient
Uniform
a = -0.006285(-0.9827)
b = -0.218420(-11.2865)

The uniform seems to be behaviourally sound. My question is regarding the normal distribution; I have students in my data who I assume might not be sensitive to fare, would you advise allowing continuous distribution within a group. For instance,
betta_fare_student follows N(b_fare_student_mean, b_fare_student_sigma).

I seem not to find literature on that type of specification besides latent class models.

Thanks and regards

Masimba.
stephanehess
Site Admin
Posts: 974
Joined: 24 Apr 2020, 16:29

Re: estimation in WTP-space

Post by stephanehess »

Hi

you say "my LL keeps getting worse as I increase the number of draws, which would mean that I am estimating the wrong model". Why do you think that means you are estimating the wrong model? As explained in the frequently asked questions, your LL will stabilise once you use a large enough number of draws. How many are you using?

Stephane
--------------------------------
Stephane Hess
www.stephanehess.me.uk
MPFMAS001
Posts: 9
Joined: 16 Dec 2021, 09:05

Re: estimation in WTP-space

Post by MPFMAS001 »

I started with 200,500 then 1000

Code: Select all

LOGNORMAL
LL(note) : -3172.792
LL(200) : -1540.384
LL(500) : -1541.772
LL(1000) : -1542.743

Code: Select all

LOGUNIFORM
LL(note) : -3172.792
LL(200) : -1541.001
LL(500) : -1544.171
stephanehess
Site Admin
Posts: 974
Joined: 24 Apr 2020, 16:29

Re: estimation in WTP-space

Post by stephanehess »

Hi

okay, so where exactly is the issue? These are still fluctuating, which is quite normal

Stephane
--------------------------------
Stephane Hess
www.stephanehess.me.uk
MPFMAS001
Posts: 9
Joined: 16 Dec 2021, 09:05

Re: estimation in WTP-space

Post by MPFMAS001 »

Thank you

I thought the LL should have improved when I used 1000 draws from 500.
Let men keep on trying with more draws.

Regards

Masimba
Post Reply