Main Content

MATLAB Function

Insert information about MATLAB Function block contents

Description

This component displays tables with information about MATLAB® code included in MATLAB Function blocks. You specify which of the following kinds of information to include in the report:

  • Function properties — Parameter settings for the MATLAB Function block

  • Argument properties — Properties of the function arguments (for example, complexity)

  • The function script — MATLAB code of the function

  • Function symbol data — Information about the user-defined and (optionally) built-in MATLAB variables and functions invoked by the MATLAB function that computes the block outputs.

  • Supporting functions — User-defined functions and, optionally, MATLAB functions that are included in the MATLAB Function block function.

For details about MATLAB Function blocks, see the MATLAB Function block reference page.

Use the MATLAB Function component within a section, paragraph, or table.

Note

To view the contents of a MATLAB Function block in a Web viewer, use the Web view feature of the Simulink® Report Generator™. In the Web view, hover your cursor over the MATLAB Function block. For details, see Create Model Web Views.

Function Properties Table

  • Include function properties: Generates a table with function property information.

  • Table title: Specifies the table title in the generated report.

    • Automatic: Use the automatically generated title.

    • Custom: Specify a custom title.

  • You can change the header text for property and value columns of the function properties table. In the Header column, double-click to change the header text. The Width column indicates the relative width, in relative terms, based on the smallest width you specify. For example, for a three-column table, if the first column width is 1, and the column width of the other two columns is 3, then the second and third columns is three times wider than the first column.

  • Grid lines: Show grid lines for the table.

  • Spans page width: Make the table as wide as the page.

Argument Summary Table

  • Include argument summary table: Generate a table with summary information about the MATLAB Function block function arguments.

  • Table title: Specifies the table title in the generated report.

    • Automatic: Use the automatically generated title.

    • Custom: Specify a custom title.

  • Argument Summary Table Options: Specify the property columns to include in the table.

    • To add a property column:

      1. In the table on the right, select a property near where you want to insert the new property column.

      2. From the list of properties to the left of the table, select a property that you want to add to the table.

      3. Click the left-arrow button.

      4. If necessary, use the up or down arrow button to position the new column.

    • To delete a property column, select the property in the table and click the right-arrow button

    • You can change the header text for property and value columns of the table. In the Header column, double-click to change the header text. The Width column indicates the relative width, in relative terms, based on the smallest width you specify. For example, for a three-column table, if the first column width is 1, and the column width of the other two columns is 3, then the second and third columns is three times wider than the first column.

  • Grid lines: Show grid lines for the table.

  • Spans page width: Make the table as wide as the page.

  • Column alignment: Align the text in each column.

    • Left

    • Center

    • Right

    • Double justified

    You can select any value present from the drop-down list. By default, the Column alignment option is set to Left.

Detailed Argument Report

  • Include detailed argument report: Generate a table with detailed information about the MATLAB Function block function arguments.

  • Argument Property Table Format Options: Specify the argument property columns to include in the table.

    • Table title: Specifies the table title in the generated report.

      • Automatic: Use the automatically generated title.

      • Custom: Specify a custom title.

    • You can change the header text for property and value columns of the table. In the Header column, double-click to change the header text.

    • Grid lines: Show grid lines for the table.

    • Spans page width: Make the table as wide as the page.

  • Include function script: Include the script for the function.

  • Include function symbol data: Generate a table that includes information about the user-defined and (optionally) built-in MATLAB variables and functions invoked by the MATLAB function that computes the block outputs.

  • Highlight script syntax: Use colors to highlight syntax keywords.

  • Include supporting functions: Include a list of functions invoked directly or indirectly by the function script. If you specify to include supporting functions in the report, also specify whether to include both MATLAB and user-defined functions or just user-defined functions.

  • Include code of user-defined supporting functions: Include the code of the user-defined supporting functions invoked directly or indirectly by the function script.

  • Supporting Function Table Format Options:

    • Table title: Specifies the table title in the generated report.

      • Automatic: Use the automatically generated title.

      • Custom: Specify a custom title.

    • You can change the header text for property and value columns of the table. In the Header column, double-click to change the header text. The Width column indicates the relative width, in relative terms, based on the smallest width you specify. For example, for a three-column table, if the first column width is 1, and the column width of the other two columns is 3, then the second and third columns is three times wider than the first column.

    • Grid lines: Show grid lines for the table.

    • Spans page width: Make the table as wide as the page.

Insert Anything into Report?

Yes. Tables and, optionally, code.

Class

rptgen_sl.csl_emlfcn