Main Content

Cell Arrays

Code generation for cell arrays

The code generator classifies a cell array as homogeneous or heterogeneous. Homogeneous cell arrays are represented as arrays in the generated code. Heterogeneous cell arrays are represented as structures in the generated code. To classify a cell array, the code generator considers the properties (class, size, complexity) of the elements and other factors such as how you use the cell array in your program. See Code Generation for Cell Arrays.

함수

coder.varsizeDeclare variable-size data
coder.cstructnameName C structure type in generated code

클래스

coder.CellTypeRepresent set of MATLAB cell arrays

도움말 항목

문제 해결

Resolve Issue: Cell Array Elements Must Be Fully Defined Before Use

Troubleshoot code generation errors when cell array elements are not defined before use.