View source: R/choice_alternatives.R
| choice_alternatives | R Documentation |
The choice_alternatives object defines the set of choice alternatives.
choice_alternatives(
J = 2,
alternatives = LETTERS[1:J],
base = NULL,
ordered = FALSE
)
## S3 method for class 'choice_alternatives'
print(x, ...)
J |
[ |
alternatives |
[ |
base |
[ If |
ordered |
[ When Otherwise, they are sorted alphabetically. |
x |
[ |
... |
Currently not used. |
An object of class choice_alternatives, i.e. a character vector of the
choice alternatives with attributes:
JThe number of choice alternatives.
baseThe name of the base alternative.
orderedDo the alternatives encode an inherent ordering?
The full set of coefficients for covariates that are constant across
alternatives (including alternative-specific constants) is not identified.
To achieve identifiability, the coefficient of alternative base
is fixed to zero. The other coefficients then have to be interpreted with
respect to base. The base alternative is marked with a * when
printing a choice_alternatives object.
choice_alternatives(
J = 3,
alternatives = c("gas", "electricity", "oil"),
base = "gas"
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.