Example -- Working with Plotting Tools
This example illustrates how to use the plotting tools to graph a workspace variable vs. an expression typed into the Add Data to Axes dialog.
Create a variable in the workspace,
plottools command to create a figure with the plotting tools attached.
Click 2D Axes in the New Subplot panel of the Figure Palette.
Once the axes appears, the Add Data button on the Plot Browser is activated. Click this button to display the Add Data to Axes dialog.
When the Add Data to Axes dialog is displayed, enter the following values:
MATLAB draws a plot of
Now add another plot to the same axes. Click Add Data again and specify the data to plot:
Select the last plot (the green line) and set the Plot Type in the Property Editor to
Stem. The plot should now look like the following picture.
|Accessing All Object Properties -- Property Inspector||Adding a Subplot|
© 1994-2005 The MathWorks, Inc.