Chapter 3. Tutorial II: Editing and Creating Visual Programs
This tutorial will show you how to modify existing visual programs and
create new ones.
In the process, it will also introduce you to a number of the most
commonly used modules.
As you become more experienced using Data Explorer, you can explore more of
each module's many options.
3.1 Editing a Visual Program: The Basics
When you open the Visual Program Editor (VPE) with the
or by choosing New Visual Program in the Startup
you will see a large blank area (the "canvas")
and two "palettes" to its left (see Figure
The palette at top lists "categories" of tools
The palette below it lists the tools in the currently selected
Selecting tools and placing icons
- Click on a tool category (e.g., Transformation) in
The tools in that category are now listed in the lower palette.
- Click on a tool in the lower palette (e.g.,
- Move the cursor into the canvas area.
Note that it becomes an inverted "L."
- Position the cursor at the point where you want the tool icon to
appear and click again to generate the icon.
Each tool icon has one or more tabs on top and bottom.
These tabs represent, respectively, input(s) to the tool module and
output(s) from it.
There are two ways to specify an input:
- by specifying a value in the configuration dialog box associated
with a particular tool
- with an arc, or line, connecting the output tab of one icon to the
input tab of another.
Specifying inputs: configuration dialog boxes
To open the configuration dialog box for a tool, either:
In the case of interactors, color maps, the Image tool, and the
Sequencer, the first procedure invokes a "control box"
(another kind of dialog box).
The second procedure always invokes a configuration
- Double click on the tool icon in the canvas, or
- Single click on (highlight) the tool icon in the canvas and select
"Configuration" from the Edit pull-down menu.
Tabs and inputs to a tool module
Each input parameter in the configuration dialog box corresponds
to an upper tab on the tool icon.
The leftmost tab corresponds to the first parameter, and so on.
Visible versus hidden parameters
At the bottom of the dialog box are
The first button "expands" the dialog box, displaying
The second button "collapses" the dialog box, hiding every
parameter whose "Hide" toggle button is activated.
(When a tool has no hidden parameters, both buttons are disabled, as
indicated by their gray labels.)
Specifying inputs: arcs and icons
A visual program is a "network" of interconnected
In the VPE window, this network is represented as a set of tool icons
connected to one another by lines ("arcs") representing the data
(Figure 4 in Tutorial I shows such a
Connecting tool icons with arcs
- Position the cursor on an output tab of an icon and
hold down the left mouse button:
the cursor becomes a downward-pointing arrow, and a parameter or data
name for that tab appears on the icon.
- Drag the cursor to another icon:
the output tab remains connected to the cursor by a highlighted line
If the connection is valid, the input tab(s) will be highlighted when
the cursor arrow touches the icon.
(If the connection is invalid, the tab(s) will not be highlighted, and
an error message will appear.
- Release the mouse button to establish a connection to a valid
- If the "receiving" icon has two or more valid input tabs, if
you release the mouse button when the cursor is on the main part
of the icon, the connection to the first (leftmost) tab
To establish a connection to a different tab requires
placing the cursor on that tab before releasing the
- You can establish a connection starting with an input tab and
dragging the arc to an output tab.
Disconnecting or moving an arc
Click on the input tab to which the arc is connected
(e.g., the input tab on Sequencer):
a highlighted arc, connected to an (Import) output tab appears:
- Disconnect the arc by dragging the cursor to an empty spot in the
canvas and releasing the mouse button, or
- Move the arc by dragging it to another icon and releasing the
mouse button to establish the new connection.
Deleting a tool icon
- Highlight the tool icon by clicking on it.
- Select Delete in the
pull-down menu. .
Moving a tool icon
Select a tool icon and drag it to the desired location before
releasing the mouse button.