visual3d:documentation:pipeline:pipeline_commands:conditional_statement
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| visual3d:documentation:pipeline:pipeline_commands:conditional_statement [2024/06/18 13:33] – sgranger | visual3d:documentation:pipeline:pipeline_commands:conditional_statement [2026/02/04 16:38] (current) – wikisysop | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | \\ | + | ====== Conditional Statement ====== |
| This command was modelled after the [[Visual3D: | This command was modelled after the [[Visual3D: | ||
| - | When the pipeline comes to an Conditional_Statement command, it will evaluate the expression using the same syntax as the [[Visual3D: | + | When the pipeline comes to an Conditional_Statement command, it will evaluate the expression using the same syntax as the [[Visual3D: |
| - | + | ||
| - | The ITERATION_PARAMETER_NAME is used to distinguish between different Conditional_Statement commands so that Conditional_Statement and Conditional_Statement_End commands can be unambiguously associated with each other. | + | |
| - | + | ||
| - | **NOTE:** If there is more than one active file then the Conditional_Statement command will be skipped. This is because the expression might be TRUE for some files and FALSE for others, leaving Visual3D in an ambiguous place. | + | |
| - | + | ||
| - | **NOTE:** This command was previously called the Expression_Loop. Scripts referring to this old command name will still work. | + | |
| - | + | ||
| - | ===== Syntax ===== | + | |
| - | + | ||
| - | ==== Conditional_Statement ==== | + | |
| + | ==== Pipeline Command ==== | ||
| + | The **Conditional Statement** command can be found in the Pipeline Workshop within the Pipeline Control folder as so: | ||
| + | < | ||
| + | Conditional_Statement | ||
| / | / | ||
| - | /[[Visual3D: | + | ! / |
| - | **;** | + | ! / |
| - | ==== Conditional_Statement_End ==== | + | ; |
| + | Conditional_Statement_End | ||
| / | / | ||
| - | **;** | + | ; |
| - | ===== Pipeline Example | + | </ |
| + | ====Command Parameters==== | ||
| + | The following table shows the command parameters and descriptions: | ||
| + | |||
| + | |**Parameter** |**Description**| | ||
| + | |**Iteration Parameter Name**|The name of the parameter that the conditional statement will apply to (defined before command)| | ||
| + | |**Expression**|Expression for the operation to be applied to the selected signals| | ||
| + | |**As Integer**|True or False: Expression value is stored as integer| | ||
| + | |||
| + | ==== Pipeline Example: Processing Walking and Running Trials | ||
| This script will prompt the user to specify if walking or running trials are being processed. Based on the user's selection, different processing will be completed. In this example, the pipeline parameter TEST will be set to 1 if the condition is Walk, and set to 2 if the condition is Run. | This script will prompt the user to specify if walking or running trials are being processed. Based on the user's selection, different processing will be completed. In this example, the pipeline parameter TEST will be set to 1 if the condition is Walk, and set to 2 if the condition is Run. | ||
| Line 79: | Line 83: | ||
| </ | </ | ||
| + | ====Notes==== | ||
| + | The ITERATION_PARAMETER_NAME is used to distinguish between different Conditional_Statement commands so that Conditional_Statement and Conditional_Statement_End commands can be unambiguously associated with each other. | ||
| + | |||
| + | **NOTE:** If there is more than one active file then the Conditional_Statement command will be skipped. This is because the expression might be TRUE for some files and FALSE for others, leaving Visual3D in an ambiguous place. | ||
| + | |||
| + | **NOTE:** This command was previously called the Expression_Loop. Scripts referring to this old command name will still work. | ||
visual3d/documentation/pipeline/pipeline_commands/conditional_statement.1718717591.txt.gz · Last modified: by sgranger
