MATLAB Report Generator | ![]() ![]() |
Category
Description
The For Loop component iteratively executes its subcomponents and must have at least one subcomponent to execute properly. This component functions like the for
loop in MATLAB, except that instead of executing a statement, it executes its subcomponents while one of the following loops is active
where varname
must be a string that is valid as a variable name. x
, y
, z
can be scalar numbers or workspace expressions that are evaluated in the workspace as scalar numbers. If any one of these is a string that cannot be evaluated as a scalar number, then the For Loop will not execute.
For example, if red
is a workspace variable, the following is a valid for
statement.
length(red)
is 3, which is a scalar number.
Attributes
This is the For Loop attribute page.
Note To view a component attribute page in the Setup File Editor, select the component in the setup file outline on the left and click on the Options tab. If the component is not in the setup file outline, you must add it to the outline first. See Building and Editing the Setup File for a discussion on how to add a component to the outline. |
Loop Type
In this section you can choose the loop type incremented indices or a vector of indices. See the MATLAB documentation for more details on the for loop and indices.
Choose this option to execute a for
loop of the following form.
for varname=x:y:z
Start: corresponds to x
in the for loop shown above
Choose this option to execute a for
loop of the following form.
for varname=[a b c ...]
a b c ...
Workspace Variable
for
loop variable) in the workspace while other components are executing.varname
in the for loop forms described above.Preview
This section shows a schematic representation of how this component will execute when the report is generated.
Insert anything into report?
Filename
![]() | <if> Elseif | Logical If | ![]() |