Written by: STATISTICA 10/28/2011 9:14 AM
Showing relationships between variables in a scatterplot is a powerful tool for understanding the data. When the scale of the variables are widely different, seeing that variability can become difficult when plotting multiple variables in one plot. STATISTICA offers a Double-Y Graph type, which allows two separate scalings for the Y axis.
The resulting graph plots some Y variables according to the Y Left scale and the remaining on the Y Right scale. In the example plot below showing baseball data (the baseball.sta data set from the STATISTICA examples is used), the number of RUNS is shown on a scale of 450 to 850 while the batting averages, (BA) is shown on a scale of .21 to .29. The scale of these two variables is very different, but the variability of the two is easy to see with the Double Y plot.
Consider that a third scale is needed to show an additional variable with a new scale. The variable Double Plays (DP) has values ranging from 120 to 215. This is well below the range for RUNS and well above the range of BA. If DP is assigned to the left Y axis with RUNS, then both will share the same scale. Both will be plotted on a scale of 0 to 900, and the relationships in the Y direction are harder to see. To create this graph, add DP to the Y left variable selection in the 2D Scatterplots dialog box.
A third Y axis can be added, such that each Y variable will have its own axis scaling. To do this, we will use the graph shown above and make some customizations via the Graph Options dialog box, which is accessed by right-clicking on the graph and selecting Graph Options from the shortcut menu.
In the tree view, select General (located under Axis). Change the Axis to Y Left (select Y left from the Axis drop-down list), and then click the Add new axis button. This will add a new axis, Y Left’.
Now, in the tree view of the Graph Options dialog box, select General (located under Plot). From the Plot drop-down list, select the variable to assign to the new axis, in this case, DP. Then, in the Assignment of axis section, change the Y axis to Custom Y Left’.
Now the DP variable is associated with the new left Y axis. The RUNS variable is still assigned to the original left Y axis. The graph now shows 3 Y axis variables with 3 separate scalings, which easily show the relationships between WIN, the winning proportion, and the 3 variables of interest, RUNS, BA, and DP.
In this plot, the legend was replaced by color coding the Y axis scales to coincide with the color of the point markers and lines.
0 comment(s) so far...