ViewBots are one-line analytic instruments used to dynamically compute a statistical or comparative measure over a subset of records and are extremely useful for analyzing tables. They are one of the most popular functions in Manifold for experienced users. When a ViewBot is configured for a drawing's table it continues to function when the drawing has the focus. For example, if we configure a ViewBot to show the average of a given field for selected items it will continue reporting the average of the selection whether or not we select items from a drawing's table or by using mouse selection commands to select objects in the drawing.
Turn on the ViewBots pane with a SHIFT-ALT-B ("B" for "ViewBot") or with a View - Panes - ViewBots command.

The ViewBots above, for example, report on those operations they have been told to conduct on the table in view. ViewBots for table windows have many functions.
To Create a ViewBot
1. Open the ViewBots pane and press the New ViewBot button. A new ViewBot line will be added to the ViewBots pane.
2. Double click onto the saved ViewBot fields to choose analytic functions and the scope of the ViewBot.
3. Press the Refresh button to update the results in that ViewBot if the ViewBot autorefresh option is not on in Tools - Options.
To Make a Selection using a ViewBot
1. Click on the target component to make it active. Open the ViewBots pane.
2. Click on the desired ViewBot to highlight it.
3. Click on one of the ViewBot pane's selection command buttons to combine the object set picked out by the ViewBot with any selection that is currently made. For example, clicking on the Subtract from Selection button will take the set of objects picked out by the ViewBot and will subtract the objects it contains from the current selection.
To Delete a ViewBot
1. Click on the desired saved ViewBot to highlight it.
2. Press the Delete ViewBot button.
To Edit a ViewBot
1. Double-click on the ViewBot to be edited, or
2. Click on the ViewBot to highlight it and press the F2 key.
ViewBots Pane Toolbar Commands
Use the New ViewBot and Delete ViewBot buttons to create and to remove ViewBots from the pane. Use Refresh and Refresh All to update the calculation in the highlighted ViewBot or in all ViewBots.
Five selection command buttons are arrayed at the top of the ViewBots pane. These commands apply to whatever set of objects is picked out by the highlighted ViewBot. If we click on a ViewBot to highlight it and then press one of these buttons, the object set picked out by that ViewBot will be combined with whatever is the current selection in the image. The selection commands allow us to use object picked out by a View ViewBot to replace the selection, to add to the selection, to subtract from the selection, to invert with the selection and to intersect the selection. For example, if we have a ViewBot that reports the number of objects for which the Elevation is greater than 100, the set of all objects picked out by this ViewBot will be combined with the existing selection with the selection command buttons.
|
|
Move Up - Move the active layer up one position in the layer stack. |
|
|
Move Down - Move the active layer down one position in the layer stack. |
|
|
Replace Selection - Replace the existing selection with the objects picked out by the highlighted ViewBot. |
|
|
Add to Selection - Add the objects picked out by the highlighted ViewBot to the existing selection. |
|
|
Subtract from Selection - Subtract the objects picked out by the highlighted ViewBot from the existing selection. |
|
|
Invert with Selection - Deselect what is in the objects set picked out by the highlighted ViewBot that was already in the existing selection and otherwise add the ViewBot's object set. |
|
|
Intersect Selection - Select only the region of overlap between the highlighted ViewBot's objects and what is in the existing selection. If there is no overlap, nothing will be selected. |
|
|
Refresh - Update the highlighted ViewBot. |
|
|
Refresh All - Update all ViewBots in the pane. |
|
|
New ViewBot - Create a new ViewBot line in the ViewBots list. |
|
|
Delete ViewBot - Delete the highlighted ViewBot. |
Add ViewBot Dialog Controls
|
Scope |
The objects upon which the ViewBot operates: all objects (or records, pixels, etc), the selection, or the name of any saved selection. |
|
Column |
The name of the field to use. Optional for some operations. For example, Number of Areas or Center X don't require a field. |
|
Operation |
The ViewBot operator to be employed. |
|
Argument |
Arguments, if required for the operator. |
|
Ignore Case |
Treat upper and lower case letters the same in strings. Used with text operators. |
|
Ignore leading and trailing whitespace |
Ignore any space or tab characters in strings. Used with text operators. " This" would be treated the same as "This". |
|
Ignore interior whitespace |
Ignore any space or tab characters within strings. Used with text operators. "Th is" would be treated the same as "This". |
|
Caption |
String to display for ViewBot results. Can include escape sequences in square brackets: [Argument] - Replace with argument in use. [Column] - Data field in use. [Operation] - Replace with the operation in use. [Scope] - Replace with scope in use, such as the name of a saved selection. [Scope Size] - Replace with the number of items in the scope. [Time] - Estimated time to compute the ViewBot. Normally used when Autorefresh is turned off to warn users of computationally intensive ViewBots that should not be casually refreshed. [Value] - Repeats the value computed and displayed in the Value column. Normally redundant. The default Caption string of [Column] [Operation] [Argument] in [Scope] creates a reasonably comprehensible sentence for most ViewBots. |
|
Autorefresh viewbot |
Command ViewBot to self-refresh on any changes in the subject component. If this value is not checked, a Refresh or Refresh All command in the ViewBots pane will be required to update the value of the 'ViewBot on any changes. |
Selection and ViewBots
Some ViewBots such as the maximum value of a column allow selection from the ViewBot and some (such as the average value of a column) do not.
See Also
See the Selection topic for examples of Replace, Add, Subtract, Invert and Intersect selection command usage.
See the ViewBots topic for examples of ViewBot usage, including use from drawings and use from tables.
ViewBot Operators for lists of operators that may be used within ViewBots.