MultinomialExample: Simulated high-dimensional multinomial regression data with...

MultinomialExampleR Documentation

Simulated high-dimensional multinomial regression data with outliers

Description

Simulated data for family = "multinomial" with n = 150 observations, p = 200 predictors (p > n) and K = 3 classes.

Usage

data("MultinomialExample")

Format

A list with components

x

training predictors, a 150 \times 200 matrix.

y

training response, a factor with levels 1, 2, 3.

outliers

indices of the contaminated training observations (1 to 15).

xtest, ytest

clean test data with 300 observations.

beta

the true 200 \times 3 matrix of slopes (the true intercepts are 0).

Details

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.

Examples

data("MultinomialExample")
table(MultinomialExample$y)

enetLTS documentation built on Nov. 22, 2026, 1:08 a.m.