Main Content

Categorical Arrays

Definition and use of categorical arrays for MATLAB Function blocks

Categorical arrays store data whose values belong to a finite set of discrete categories. With categorical arrays, you can provide efficient data storage and meaningful names for categories in MATLAB® code intended for code generation.


MATLAB FunctionInclude MATLAB code in models that generate embeddable C code


Code Generation for Categorical Arrays

Use categorical arrays in MATLAB code intended for code generation.

Categorical Array Limitations for Code Generation

Adhere to code generation restrictions for categorical arrays.