Questions tagged [mlogit]

Multinomial logistic regression is a classification method that generalizes logistic regression to multiclass problems.

Multinomial Logistic Regression

In statistics, multinomial logistic regression is a classification method that generalizes logistic regression to multiclass problems, i.e. with more than two possible discrete outcomes. That is, it is a model that is used to predict the probabilities of the different possible outcomes of a categorically distributed dependent variable, given a set of independent variables (which may be real-valued, binary-valued, categorical-valued, etc.).

Multinomial logistic regression is known by a variety of other names, including multiclass LR, multinomial regression, softmax regression, multinomial logit, maximum entropy (MaxEnt) classifier, conditional maximum entropy model.

Source: http://en.wikipedia.org/wiki/Multinomial_logistic_regression

289 questions
1
vote
0 answers

mlogit: multinominal probit model with intercept returns error

I am experiencing a problem fitting a multinominal probit with the package mlogit. I am interested in a model with a single alternative specific covariate with a generic coefficient (more details on notation here). In brief, 2001 respondents are…
1
vote
1 answer

mlogit data transformation, R

I have a dataset that looks like this: Observation Outcome VariableA VariableB VariableC 1 1 1.27 0.2 0.81 2 0 0.30 0.45 0.70 3 -1 …
carsentdum
  • 57
  • 6
1
vote
2 answers

Creating new variable in wide data format, R

I have transformed my data into a wide format using the mlogit.data function in order to be able to perform an mlogit multinomial logit regression in R. The data has three different "choices" and looks like this (in its wide format): Observation …
carsentdum
  • 57
  • 6
1
vote
1 answer

Matrix has unexpected missing cells when collecting z-statistics from mlogit

I wish to run a series of multinomial logits (600ish per covariate of interest) and gather the z-statistics from each of these (I do not care about the order in which these are recorded). These mlogits are run on a small piece of my data (sharing a…
amquack
  • 837
  • 10
  • 24
1
vote
1 answer

Error in a bivariate logistic model in R

I have an unexpected error in my research. Let me show you several code chunks from my research. Hope, you'll help me. I have two binary variables: alco and smoke that were generated like this: smoke<- factor(with(df,…
1
vote
1 answer

function return as another function parameter with eval() in R

I have a difficulty in learning how to use eval() to evaluate a function, suppose i have a function: sq <- function(y){ y**2 } u can evaluate this function like this: call <- match.call(expand.dots = FALSE) call[[1]] <- as.name('sq') call$y <-…
John
  • 309
  • 3
  • 12
1
vote
0 answers

elastic net with mlogit

I am working on multinomial logistic regression with the mlogit package. I would like to add the elastic net penalty (Hastie and Zou, 2005) to the likelihood function. As in:…
John
  • 309
  • 3
  • 12
1
vote
0 answers

Including an offset variable [or constraining a coefficient to 1] using mlogit R

I´ve been estimating some MNL models in R using mlogit. The package works very well but it seems that it does not allow to include offset variables. I read the package documentation in order to see whether it allowed to constrain a coefficient when…
Dr. Wall
  • 11
  • 2
1
vote
1 answer

Data shape and specifying model in mlogit for R

I am trying to use the mlogit package in R to do some analyses. Unfortunately, I am a bit confused by how to specify the appropriate model given the type of data I have. Specifically, my data are of the following type: Individual Choice1 Choice2 …
user62037
  • 31
  • 2
1
vote
1 answer

R: mlogit with alternative-specific variable

I am trying to estimate a multinomial logit model with the mlogit package. I don't know how to deal with variables that don't apply to all alternatives. For example, I have four transportation modes (walk, bike, public transport and car) and the…
sbb2018
  • 11
  • 3
1
vote
0 answers

conjoint analysis with ordinal data in R

I would like to conjoint analysis with R of an experiment I created with orthogonal design. The code I found for conjoint analysis had a rating column beside the attributes for each choice. This is the code I used to implement conjoint. conjoint1 <-…
Tateishi
  • 81
  • 1
  • 6
1
vote
1 answer

R mlogit model, , missing value where TRUE/FALSE needed, 20 invalid factor level warnings

I'm trying to run a multinomial logistic regression using the mlogit package in R. I've uploaded the data here https://drive.google.com/file/d/0B_o3xTWAYdbuRGw0dzNFRzd2NEk/view?usp=sharing. The data contains two different choice variables which I…
ADF
  • 522
  • 6
  • 14
1
vote
0 answers

NaNs produced and system is exactly singular error while using mnlogit R package

I am currently working on a behavior modelling project that involves estimating a multinomial logit model. After searching over the internet I came across the mnlogit package which seems very suitable for me. The problem I am trying to model can be…
Guidotti
  • 13
  • 3
1
vote
0 answers

r mlogit error: system is computationally singular: reciprocal condition number

I am using library(mlogit) in R and I am stuck at the error message saying: Error in solve.default(H, g[!fixed]) : system is computationally singular: reciprocal condition number = 8.41187e-25 Using mlogit.data function I have made following…
emdroll
  • 73
  • 5
1
vote
0 answers

How to plot the predicted probability based on multilevel multinomial logit model in SAS?

I want to plot the predicted age(including two age variations: age and age2), period and cohort variations in the sex disparities in job based on the following model, how should I add SAS codes? proc glimmix data=model noitprint noclprint; …
Vesper
  • 87
  • 1
  • 8