setColWidth
Specify column widths for table in Model Advisor analysis results
Description
setColWidth(
specifies the widths of columns for a table in Model Advisor
results.tableObj,column,relativeWidth)
Examples
Specify column widths for a table in your
Model Advisor results by using
setColWidth in a check callback
function in your sl_customization
file.
Inside your check callback function, you can customize the check results to return a table. In this example, the first column of the table has the default width. The second column is twice as wide as the first column. The third column is three times as wide as the first column.
% Create table for displaying results numRows = 1; numCols = 3; table = ModelAdvisor.Table(numRows,numCols); % Fill in table with example entries setEntry(table,1,1,'entry 1'); setEntry(table,1,2,'entry 2'); setEntry(table,1,3,'entry 3'); % Specify widths of columns in table setColWidth(table,1,1); % set column 1 to the default width setColWidth(table,2,2); % make column 2 twice as wide as column 1 setColWidth(table,3,3); % make column 3 three times as wide as column 1
Input Arguments
Table of Model Advisor results, specified as a ModelAdvisor.Table object.
Column of the table, specified as an integer.
Example: 2
Relative width of column, specified as an integer.
The column width is relative to the width of the entire table. For example, this code makes the second column twice as wide as the first column and the third column three times as wide as the first column:
setColWidth(table,1,1); % set column 1 to the default setColWidth(table,2,2); % make column 2 twice as wide as column 1 setColWidth(table,3,3); % make column 3 three times as wide as column 1
ModelAdvisor.Table have a
relativeWidth of
1.Example: 3
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Sélectionner un site web
Choisissez un site web pour accéder au contenu traduit dans votre langue (lorsqu'il est disponible) et voir les événements et les offres locales. D’après votre position, nous vous recommandons de sélectionner la région suivante : .
Vous pouvez également sélectionner un site web dans la liste suivante :
Comment optimiser les performances du site
Pour optimiser les performances du site, sélectionnez la région Chine (en chinois ou en anglais). Les sites de MathWorks pour les autres pays ne sont pas optimisés pour les visites provenant de votre région.
Amériques
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)