Skip to main content
User seems to have wanted a multinomial dependent variable (not Y=0/1, but Y=0,1,2 etc)
Source Link

I am not sure if you are familiar with R, put the R package glmnet containts "extremely efficient procedures for fitting the entire lasso or elastic-netregularization path for linear regression, logistic and multinomial regression models, Poisson regression and the Cox model".

The general syntax to "Fit a generalized linear model via penalized maximum likelihood" would be:

    fit=glmnet(x,y,family="binomial")

where x is your input matrix of independent variables, and y is your dependent variable (response variable). The binomial family would be for your binary dependent variable or family "multinomial" for a multinomial dependent variable.

I am not sure if you are familiar with R, put the R package glmnet containts "extremely efficient procedures for fitting the entire lasso or elastic-netregularization path for linear regression, logistic and multinomial regression models, Poisson regression and the Cox model".

The general syntax to "Fit a generalized linear model via penalized maximum likelihood" would be:

    fit=glmnet(x,y,family="binomial")

where x is your input matrix of independent variables, and y is your dependent variable (response variable). The binomial family would be for your binary dependent variable.

I am not sure if you are familiar with R, put the R package glmnet containts "extremely efficient procedures for fitting the entire lasso or elastic-netregularization path for linear regression, logistic and multinomial regression models, Poisson regression and the Cox model".

The general syntax to "Fit a generalized linear model via penalized maximum likelihood" would be:

    fit=glmnet(x,y,family="binomial")

where x is your input matrix of independent variables, and y is your dependent variable (response variable). The binomial family would be for your binary dependent variable or family "multinomial" for a multinomial dependent variable.

Source Link

I am not sure if you are familiar with R, put the R package glmnet containts "extremely efficient procedures for fitting the entire lasso or elastic-netregularization path for linear regression, logistic and multinomial regression models, Poisson regression and the Cox model".

The general syntax to "Fit a generalized linear model via penalized maximum likelihood" would be:

    fit=glmnet(x,y,family="binomial")

where x is your input matrix of independent variables, and y is your dependent variable (response variable). The binomial family would be for your binary dependent variable.