Error with mixed logit model in R using mlogit

I get an error running the following mixed multinomial model:

m6 <- mlogit(Response ~ 1 | 1 | Cost + Time + WalkTime, reflevel = "PT", data =TM6)
summary(m6)

m6.rpar <- rep("n", length=length(m6$coef))
names(m6.rpar) <- names(m6$coef)
m6.rpar

m4.hier <- mlogit(Response ~ 1 | Age + Sex + HomeLoca + CarOwn + CarHouse + LTimePT + LTimeCar + UmwFrei1 + DistPT1 + FrqInfo1Neu | Cost + Time + WalkTime, reflevel = "PT", data =TM6, panel=TRUE, rpar = m6.rpar, correlation=FALSE)
summary(m4.hier)

The error is the following:

Error in mlogit(Response ~ 1 | Age + Sex + HomeLoca + CarOwn + CarHouse +  : 
  no individual index

There was an update on the mlogit package (https://cran.r-project.org/web/packages/mlogit/mlogit.pdf). This syntax worked last year but now it provides errors. Does anyone know what I have to change?
Thank you very much for your help!

I'm guessing that because you are using rpar, its expected that you'd have ID's.
Do your observations have IDS ?

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.