| MultinomialExample | R Documentation |
Simulated data for family = "multinomial" with n = 150 observations,
p = 200 predictors (p > n) and K = 3 classes.
data("MultinomialExample")
A list with components
xtraining predictors, a 150 \times 200 matrix.
ytraining response, a factor with levels 1, 2, 3.
outliersindices of the contaminated training observations (1 to 15).
xtest, ytestclean test data with 300 observations.
betathe true 200 \times 3 matrix of slopes (the true intercepts are 0).
The predictors are independent standard normal. Each class is driven by its own predictors:
\beta_{1,1} = \beta_{2,1} = 3 (class 1), \beta_{3,2} = \beta_{4,2} = 3 (class 2),
\beta_{5,3} = \beta_{6,3} = 3 (class 3); the class probabilities follow the multinomial
logistic model. The first 15 observations are contaminated: predictors 1 and 2 are shifted by 5
(far out in the direction of class 1) and the label is set to 3, so they are bad leverage points.
Values are rounded to three decimals. The generating code is in the data-raw directory of the
package repository on GitHub.
data("MultinomialExample")
table(MultinomialExample$y)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.