GroupFusedMulti: Group Fused Multinomial Logistic Regression

Description Usage Arguments Details Value Author(s) References Examples

Description

This routine fits the group fused multinomial logistic regression model, which uses fusion shrinkage to automatically combine response categories.

Usage

1
GroupFusedMulti(Y,X,lambda,H,tol1=10^-7,tol2=10^-7,TD=2,rho=10^-8,tau1=10^-9,iter=1e3)

Arguments

Y

A matrix of response category counts where the columns represent the categories and rows represent the observations. Currently supported for n=1.

X

A matrix of predictor variables. The columns represent predictors and rows represent observations.

lambda

tuning parameter for fusion penalty

H

An indicator matrix representing the edge set of the penalty set. The matrix is square and symmetric with dimension number of response categories, and if two categories are in the penalty set a 1 should be in the row column combination.

tol1

Convergence tolerance for ADMM

tol2

Convergence tolerance of ADMM

TD

Step size Adjustment for iterative step size

rho

ADMM step-size parameter, iterative implementation

tau1

The threshold parameter to 0 for final estimates

iter

Maximum number of iterations of the algorithm

Details

Implements the ADMM algorithm for the group fused multinomial regression estimates proposed by Price et. al.

Value

The function returns a list:

Coeff

Final coefficient estimates for the gfmr model

Approx

Final iterates of beta before threshold

Z

Final iterate of Z in the ADMM algorithm

lambda

Tuning Parameter

Converge

Indicator of algorithm convergence

NGroups

Number of groups in final estimates

Groups

The response category groups in the final estimates

Author(s)

Brad Price, brad.price@mail.wvu.edu.

References

Price, B.S, Geyer, C.J. and Rothman, A.J. "Automatic Response Category Combination in Multinomial Logistic Regression." https://arxiv.org/abs/1705.03594.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
## Not run: data(nes96)
attach(nes96)
Response=matrix(0,944,7)
for(i in 1:944){
  if(PID[i]=="strRep"){Response[i,1]=1}
  if(PID[i]=="weakRep"){Response[i,2]=1}
  if(PID[i]=="indRep"){Response[i,3]=1}
  if(PID[i]=="indind"){Response[i,4]=1}
  if(PID[i]=="indDem"){Response[i,5]=1}
  if(PID[i]=="weakDem"){Response[i,6]=1}
  if(PID[i]=="strDem"){Response[i,7]=1}
}

Hmat=matrix(1,dim(Response)[2],dim(Response)[2])
diag(Hmat)=0
ModMat<-lm(popul~age,x=TRUE)$x

X=cbind(ModMat[,1],apply(ModMat[,-1],2,scale))
mod<-GroupFusedMulti(Response,X,lambda=2^4.3,H=Hmat2,rho=10^2,iter=50,tol1=10^-4,tol2=10^-4)
predict(mod,X[1,])

## End(Not run)

gfmR documentation built on May 1, 2019, 8:41 p.m.