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.

Search found 11 matches

by gregorymacfarlane
11 Jul 2023, 15:20
Forum: Errors during model validation and/or estimation.
Topic: Unable to compute analytical gradients
Replies: 8
Views: 5671

Re: Unable to compute analytical gradients

Ah, well that was silly. I don't think I had that issue with my earlier code. But it works now. Thanks for being the proofreader here.
by gregorymacfarlane
10 Jul 2023, 15:26
Forum: Errors during model validation and/or estimation.
Topic: Unable to compute analytical gradients
Replies: 8
Views: 5671

Re: Unable to compute analytical gradients

I have pushed updates to the code and model output files at the GitHub link in the OP.
by gregorymacfarlane
06 Jul 2023, 17:15
Forum: Errors during model validation and/or estimation.
Topic: Unable to compute analytical gradients
Replies: 8
Views: 5671

Re: Unable to compute analytical gradients

Thanks for your response. Interesting about the utility functions in lapply vs for. I just did a little test with the same model, and see that if I do V = list() ### compute class-specific utilities V[["walk_alone" ]] = ... Then the hessian is singular and no standard errors are returned. ...
by gregorymacfarlane
03 Jul 2023, 22:41
Forum: Errors during model validation and/or estimation.
Topic: Unable to compute analytical gradients
Replies: 8
Views: 5671

Unable to compute analytical gradients

I am estimating a multinomial logit model where observations have eight alternatives, and all are available. The data is available on GitHub https://github.com/urban-stack/kids-independent-travel/blob/main/data/all-purpose/usa-2017-all.rds , and the code to estimate the models is available on GitHub...
by gregorymacfarlane
09 Apr 2021, 23:34
Forum: Bug reports
Topic: Cannot check for panel data id on a tibble
Replies: 1
Views: 7904

Cannot check for panel data id on a tibble

I wrote about this in another post that has yet to be moderated, but I can link to it there. There can be a problem identifying the length of unique ID's when the database object is an instance of class tibble. The error arises from this line in apollo_validateControls() length(unique(database[, apo...
by gregorymacfarlane
09 Apr 2021, 04:22
Forum: Post-estimation analysis/use of results
Topic: Export model summary from Apollo objects to LaTeX
Replies: 5
Views: 8236

Re: Export model summary from Apollo objects to LaTeX

Yes, I agree this looks very good! Getting tidy, glance, and augment methods written for apollo objects will help users access tools like modelsummary (which is amazing, and should be the model summary package to end all model summary packages), coefplot, and lots of other great pieces of the R ecos...
by gregorymacfarlane
09 Apr 2021, 02:51
Forum: Feature requests
Topic: Output directory
Replies: 1
Views: 7452

Output directory

The apollo_saveOutput function does not allow the user to change which directory the model outputs get written to. This would be a very handy feature to allow users to integrate apollo into their existing data workflows. I would be happy to send a pull request with this improvement if I were pointed...
by gregorymacfarlane
09 Apr 2021, 00:42
Forum: Data preparation, processing and pre-estimation analysis
Topic: Need to multiply observations for same individual?
Replies: 1
Views: 6504

Need to multiply observations for same individual?

I'm in my first three hours of using apollo (outside of the examples). I'm trying to use it to estimate the following model from the mlogit package: library(mlogit) data("TravelMode", package = "AER") mlogit(choice ~ wait + vcost | size, TravelMode) I believe that I have finally ...
by gregorymacfarlane
22 Mar 2021, 15:35
Forum: Feature requests
Topic: Spatial autocorrelations within choice model
Replies: 4
Views: 11142

Re: Spatial autocorrelations within choice model

There are (at least) two different ways in which spatial correlation would show up in choice models. 1. Spatially correlated error between alternatives. This happens when there is some spatial attribute of the choice alternative, like in a destination choice model. That would seem to be handled with...
by gregorymacfarlane
18 Mar 2021, 18:27
Forum: Feature requests
Topic: Spatial autocorrelations within choice model
Replies: 4
Views: 11142

Re: Spatial autocorrelations within choice model

I have not done this, but am also very interested in knowing how it might be done.