IconDecision Tree View (JavaScript)0 ×

KNIME JavaScript Base Views version 3.6.0.v201807091518 by KNIME AG, Zurich, Switzerland

A plot of the provided decision tree using a JavaScript based library. The view can be accessed either via the "interactive view" action on the executed node or in a KNIME Server web portal page.

The view shows a decision tree consisting of a number of nodes. The class label and the class counts displayed inside the nodes correspond to those of the training data. This especially means that the shown frequencies do not correspond to the rows used for selection (unless you use the full training dataset for selection).

The configuration of the node lets you choose the number of rows to be used for selection and to enable certain controls, which are then available in the view. This includes the possibility to set a title. Enabling or disabling these controls via the configuration dialog might not seem useful at first glance but has benefits when used in a web portal/wizard execution where the end user has no access to the workflow itself.

Additionally a static SVG image can be rendered, which is then made available at the first output port.

Note, this node is currently under development. Future versions of the node might have more or changed functionality.

The node supports custom CSS styling. You can simply put CSS rules into a single string and set it as a flow variable 'customCSS' in the node configuration dialog. You will find the list of available classes and their description on our documentation page.


Decision Tree Plot Options

Create image at outport
If an image is supposed to be rendered during execute for the upper outport. Disable this option if image is not needed or creation is too time consuming.
Expanded levels
Specifies how many levels of the tree are initially expanded. In case of a 0 only the root node is displayed, in case of a 1 also the children of the root are displayed, and so on. (Initially disabled if a different node status is specified in the view and saved as new default.)
Reset node status
If selected the node status is reset to the status corresponding to the specified expanded levels. (Disabled if there is no node status from the view available.)
Maximum number of rows
Use this numerical value to restrict the number of rows used for selection.
Selection column name
Name of the appended column containing boolean values to indicate, whether a point was selected in the view or not (disabled if no table is connected).

General Plot Options

Chart title (*)
The title of the graph shown above the generated image. If left blank, no title will be shown.
Chart subtitle (*)
The subtitle of the graph shown above the generated image. If left blank, no subtitle will be shown.
Display fullscreen button
Webportal option. If checked, a button is shown in the webportal to open the view in fullscreen mode.
Background color
The color of the background of the image.
Tree area color
The background color of the decision tree.
Node background color
The background color of the individual decision tree nodes.
Decimal digits
The number of decimals to show for numeric thresholds in the node conditions.
Decimal separator
The decimal separator to use for numeric thresholds in the node conditions.
Thousands separator
The separator to be used to separate thousands (i.e. " " corresponds to "100 000").
Custom prefix
A custom prefix for numbers displayed in node conditions.
Custom postfix
A custom postfix for numbers displayed in node conditions (i.e. to display currency).
Negative sign
A custom negative sign to use in node conditions.
Negative before string
A prefix that is used for negative numbers only. Inserted before the prefix.
Truncation limit
In the view long strings are abbreviated to avoid cluttering. The truncation limit specifies the maximal length of a string. For abbreviated strings a tooltip is added that displays the full string.

View Controls

Enable view edit controls
If checked all edit controls selected below will be rendered in the view. Unchecking this option disables all edit controls.
Enable title edit controls
Renders a text box to change the chart title in the view.
Enable subtitle edit controls
Renders a text box to change the chart subtitle in the view.
Enable selection
Enables or disables the selection feature. When enabled, checking the selection checkbox in a decision tree node selects all rows that run through the decision tree node. The selection is propagated as an additional column in the output table of this node.
Display selection reset button
When enabled, a button is displayed in the view that allows to clear the current selection.
Publish selection events
When enabled, the view publishes the selections performed in it when it is run in the KNIME Server web portal.
Subscribe to selection events
When enabled, the view will react to selection events in the KNIME Server web portal
Enable zooming
Enable zooming on the plot using the mouse wheel.

Interactive View: Decision Tree View

Displays a tree plot of the provided decision tree.

Input Ports

Decision tree to display.
Data which should be run through the decision tree.

Output Ports

SVG image rendered by the JavaScript implementation of the decision tree plot.
Data table containing the input data appended with a column, that represents the selection made in the decision tree view.

Best Friends (Incoming)

Best Friends (Outgoing)


Update Site

To use this node in KNIME, install KNIME JavaScript Base Views from the following update site:

Wait a sec! You want to explore and install nodes even faster? We highly recommend our NodePit for KNIME extension for your KNIME Analytics Platform.