array2table
Convert a matrix to a table.
Syntax
Section titled “Syntax”T = array2table(A)T = array2table(A, 'VariableNames', {'name1', ...})Description
Section titled “Description”Each column of A becomes one column variable in the table. Variable names default to 'A_1', 'A_2', … unless 'VariableNames' is provided.
Examples
Section titled “Examples”array2table(magic(3))array2table([1 2; 3 4], 'VariableNames', {'x', 'y'})See also
Section titled “See also”table2array— Convert a table to a matrix.table— Create a table — a heterogeneous tabular data container.cell2table— Convert a cell array to a table.