mcd2: Multinomial Canonical Decomposition Model for a multinomial...

View source: R/mcd2.R

mcd2R Documentation

Multinomial Canonical Decomposition Model for a multinomial outcome

Description

The function mcd2 fits the multinomial canonical decomposition model to a multinomial outcome i.e. a double constrained reduced rank multinomial logistic model

Usage

mcd2(X, G, Z, S = 2, trace = TRUE, maxiter = 65536, dcrit = 1e-06)

Arguments

X

An N by P matrix with predictor variables

G

An N times C class indicator matrix

Z

design matrix for response

S

Positive number indicating the dimensionality of teh solution

trace

whether progress information should be printed on the screen

maxiter

maximum number of iterations

dcrit

convergence criterion

Value

This function returns an object of the class mcd with components:

call

function call

Xoriginal

Matrix X from input

G

Class indicator matrix G

X

Scaled X matrix

mx

Mean values of X

sdx

Standard deviations of X

pnames

Variable names of profiles

xnames

Variable names of predictors

znames

Variable names of responses

Z

Design matrix Z

m

main effects

Bx

regression weights for X

Bz

regression weights for Z

A

regression weights (Bx Bz')

U

matrix with coordinates for row-objects

V

matrix with coordinates for column-objects

Ghat

Estimated values of G

deviance

value of the deviance at convergence

df

number of paramters

AIC

Akaike's informatoin criterion

iter

number of main iterations from the MM algorithm

svd

Singular value decomposition in last iteration

Examples

## Not run: 
data(dataExample_lpca)
Y = as.matrix(dataExample_lpca[ , 1:5])
X = as.matrix(dataExample_lpca[ , 9:13])
#unsupervised
output = mcd1(X, Y, S = 2, ord.z = 2)

## End(Not run)


lmap documentation built on April 3, 2025, 5:47 p.m.

Related to mcd2 in lmap...