Main Content

setRowHeadingValign

Specify vertical alignment for row heading

    Description

    setRowHeadingValign(tableObj, row, alignment) sets the vertical alignment for the specified row, row, in the Model Advisor table object, tableObj, to the alignment specified by alignment.

    Note

    The function setRowHeadingValign 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.

    Examples

    collapse all

    This example shows how to create a Model Advisor table object, add row headings, and set vertical alignment for the row headings.

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

    table1 = ModelAdvisor.Table(2, 3);

    Add the titles and set vertical alignment for row headings to the middle for the Model Advisor table object table1.

    setRowHeading(table1, 1, 'Header 1');
    setRowHeadingValign(table1, 1, 'middle');
    
    setRowHeading(table1, 2, 'Header 2');
    setRowHeadingValign(table1, 2, 'middle');
    

    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 rows to create in the Model Advisor results table, specified as an integer.

    Example: 5

    Data Types: int

    Row heading vertical alignment, specified as top, middle, or bottom.

    alignmentDefinition
    topVertically align row heading to the top.
    middleVertically align row heading to the middle.
    bottomVertically align row heading to the bottom.

    Version History

    Introduced in R2006b