Contenido principal

setColHeading

Specify column heading for table

    Description

    setColHeading(tableObj,column,heading) adds the heading, heading, for the specified column, column, in the Model Advisor table object tableObj.

    Note

    The function setColHeading is for formatting tables in Model Advisor analysis results with Simulink® Check™. For more information, see Simulink Check.

    For information on how to use tables in MATLAB®, see Create Tables and Assign Data to Them.

    example

    Examples

    collapse all

    This example shows how to create a Model Advisor table object and add column headings.

    Use ModelAdvisor.Table to create a Model Advisor table object with two rows and three columns.

    table1 = ModelAdvisor.Table(2,3);
    

    Specify column headings for the three columns in the Model Advisor table object.

    setColHeading(T1,1,'Header 1');
    setColHeading(T1,2,'Header 2');
    setColHeading(T1,3,'Header 3');

    For more information on how to format check results, see Define Custom Model Advisor Checks.

    Input Arguments

    collapse all

    Table of Model Advisor results, specified as a ModelAdvisor.Table object.

    Number of columns to create in the Model Advisor results table, specified as an integer.

    Example: 2

    Data Types: int

    Column heading title, specified as a character vector, Advisor.Element object, or Advisor.Element object array.

    Example: 'Heading 1'

    Version History

    Introduced in R2006b