The Visualize Panel
Now take a look at Weka’s data visualization facilities. These work best with
numeric data, so we use the iris data. Load iris.arff, which contains the iris dataset
of Table 1.4 containing 50 examples of three types of Iris: Iris setosa, Iris versicolor,
and Iris virginica.
Click the Visualize tab to bring up the Visualize panel (shown in Figure 11.17).
Click the first plot in the second row to open up a window showing an enlarged plot
using the selected axes. Instances are shown as little crosses, the color of which
depends on the instance’s class. The x-axis shows the sepallength attribute, and the
y-axis shows petalwidth.
Clicking on one of the crosses opens up an Instance Info window, which lists
the values of all attributes for the selected instance. Close the Instance Info window
again.
The selection fields at the top of the window containing the scatter plot determine
which attributes are used for the x- and y-axes. Change the x-axis to petalwidth and
the y-axis to petallength. The field showing Color: class (Num) can be used to
change the color coding.
Each of the barlike plots to the right of the scatter plot window represents a
single attribute. In each bar, instances are placed at the appropriate horizontal
position and scattered randomly in the vertical direction. Clicking a bar uses that
attribute for the x-axis of the scatter plot. Right-clicking a bar does the same for
the y-axis. Use these bars to change the x- and y-axes back to sepallength and
petalwidth.
The Jitter slider displaces the cross for each instance randomly from its true
position, and can reveal situations where instances lie on top of one another.
Experiment a little by moving the slider.
The Select Instance button and the Reset, Clear, and Save buttons let you modify
the dataset. Certain instances can be selected and the others removed. Try the Rectangle
option: Select an area by left-clicking and dragging the mouse. The Reset
button changes into a Submit button. Click it, and all instances outside the rectangle
are deleted. You could use Save to save the modified dataset to a file. Reset restores
the original dataset.