UniformDesignMatrix {CatReg}R Documentation

Create a design matrix of categorical variables.

Description

Function for use in simulations, creating design matrix of categorical variables where each column is uniformly randomly distributed and independent.

Usage

UniformDesignMatrix(n, p, c)

Arguments

n

Number of observations

p

Number of variables

c

Number of categories within each variable

Value

A data frame of categorical (factor) variables.

Examples

x = UniformDesignMatrix(100, 10, 8)

[Package CatReg version 2.0.3 Index]