Saturday 3 November 2012

CHAPTER TWO- PLOTTING COMMANDS

2.1 GRAPH FUNCTIONS


MATLAB has built-in functions that allow one to generate bar charts, x-y,
polar, contour and 3-D plots, and bar charts. MATLAB also allows one to
give titles to graphs, label the x- and y-axes, and add a grid to graphs. In
addition, there are commands for controlling the screen and scaling. Table 2.1
shows a list of MATLAB built-in graph functions. One can use MATLAB’s
help facility to get more information on the graph functions.

Table 2.1
Plotting Functions
FUNCTION
DESRIPTION
axis- freezes the axis limits
bar -plots bar chart
contour- performs contour plots
ginput- puts cross-hair input from mouse
grid- adds grid to a plot
gtext -does mouse positioned text
histogram -gives histogram bar graph
hold- holds plot (for overlaying other plots)
loglog- does log versus log plot
mesh- performs 3-D mesh plot
meshdom- domain for 3-D mesh plot
pause- wait between plots
plot- performs linear x-y plot
polar -performs polar plot
semilogx- does semilog x-y plot (x-axis logarithmic)
semilogy- does semilog x-y plot (y-axis logarithmic)
shg -shows graph screen
stairs- performs stair-step graph
text- positions text at a specified location on graph
title -used to put title on graph
xlabel- labels x-axis
ylabel -labels y-axis

No comments:

Post a Comment