disp

Class: dataset

Display dataset array

The dataset data type might be removed in a future release. To work with heterogeneous data, use the MATLAB® table data type instead. See MATLAB table documentation for more information.

Syntax

disp(ds)

Description

disp(ds) prints the dataset array ds, including variable names and observation names (if present), without printing the dataset name. In all other ways it's the same as leaving the semicolon off an expression.

For numeric or categorical variables that are 2-D and have three or fewer columns, disp prints the actual data using either short g, long g, or bank format, depending on the current command line setting. Otherwise, disp prints the size and type of each dataset element.

For character variables that are 2-D and 10 or fewer characters wide, disp prints quoted strings. Otherwise, disp prints the size and type of each dataset element.

For cell variables that are 2-D and have three or fewer columns, disp prints the contents of each cell (or its size and type if too large). Otherwise, disp prints the size of each dataset element.

For time series variables, disp prints columns for both the time and the data. If the variable is 2-D and has three or fewer columns, disp prints the actual data Otherwise, disp prints the size and type of each dataset element.

For other types of variables, disp prints the size and type of each dataset element.

See Also

| |

Was this topic helpful?