miscmethods.mlogit: Methods for mlogit objects

Description Usage Arguments

Description

Miscellaneous methods for mlogit objects.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
## S3 method for class 'mlogit'
residuals(object, outcome = TRUE, ...)

## S3 method for class 'mlogit'
df.residual(object, ...)

## S3 method for class 'mlogit'
terms(x, ...)

## S3 method for class 'mlogit'
model.matrix(object, ...)

model.response.mlogit(object, ...)

## S3 method for class 'mlogit'
update(object, new, ...)

## S3 method for class 'mlogit'
print(
  x,
  digits = max(3, getOption("digits") - 2),
  width = getOption("width"),
  ...
)

## S3 method for class 'mlogit'
logLik(object, ...)

## S3 method for class 'mlogit'
summary(object, ..., type = c("chol", "cov", "cor"))

## S3 method for class 'summary.mlogit'
print(
  x,
  digits = max(3, getOption("digits") - 2),
  width = getOption("width"),
  ...
)

## S3 method for class 'mlogit'
idx(x, n = NULL, m = NULL)

## S3 method for class 'mlogit'
idx_name(x, n = NULL, m = NULL)

## S3 method for class 'mlogit'
predict(object, newdata = NULL, returnData = FALSE, ...)

## S3 method for class 'mlogit'
fitted(
  object,
  type = c("outcome", "probabilities", "linpred", "parameters"),
  outcome = NULL,
  ...
)

## S3 method for class 'mlogit'
coef(
  object,
  subset = c("all", "iv", "sig", "sd", "sp", "chol"),
  fixed = FALSE,
  ...
)

## S3 method for class 'summary.mlogit'
coef(object, ...)

Arguments

outcome

a boolean which indicates, for the fitted and the residuals methods whether a matrix (for each choice, one value for each alternative) or a vector (for each choice, only a value for the alternative chosen) should be returned,

...

further arguments.

x, object

an object of class mlogit

new

an updated formula for the update method,

digits

the number of digits,

width

the width of the printing,

type

one of outcome (probability of the chosen alternative), probabilities (probabilities for all the alternatives), parameters for individual-level random parameters for the fitted method, how the correlated random parameters should be displayed : "chol" for the estimated parameters (the elements of the Cholesky decomposition matrix), "cov" for the covariance matrix and "cor" for the correlation matrix and the standard deviations,

n, m

see dfidx::idx()

newdata

a data.frame for the predict method,

returnData

for the predict method, if TRUE, the data is returned as an attribute,

subset

an optional vector of coefficients to extract for the coef method,

fixed

if FALSE (the default), constant coefficients are not returned,


mlogit documentation built on Oct. 23, 2020, 5:29 p.m.