Professional Documents
Culture Documents
Introduction
This appendix lists the MATLAB functions as they are grouped in the Help
Desk by subject. Each table contains the function names and brief descriptions.
For complete information about any of these functions, refer to the Help Desk
and either:
• Select the function from the MATLAB Functions list (By Subject or
By Index), or
• Type the function name in the Go to MATLAB function field and click Go.
Note If you are viewing this book from the Help Desk, you can click on any
function name and jump directly to the corresponding MATLAB function
page.
2
General Purpose Commands
3
MATLAB Quick Reference
4
Logical Functions
5
MATLAB Quick Reference
6
Specialized Matrices
7
MATLAB Quick Reference
8
Coordinate System Conversion
9
MATLAB Quick Reference
10
Polynomial and Interpolation Functions
11
MATLAB Quick Reference
12
Sound Processing Functions
13
MATLAB Quick Reference
14
Bitwise Functions
15
MATLAB Quick Reference
Object Functions
Multidimensional Array Functions
Using the object functions you can create objects, cat Concatenate arrays
detect objects of a given class, and return the class
flipdim Flip array along a specified
of an object.
dimension
ind2sub Subscripts from linear index
Object Functions
ipermute Inverse permute the dimensions
class Create object or return class of
of a multidimensional array
object
ndgrid Generate arrays for
isa Detect an object of a given class
multidimensional functions and
interpolation
Cell Array Functions ndims Number of array dimensions
Cell arrays are arrays comprised of cells, which can permute Rearrange the dimensions of a
hold any MATLAB data type such as text, numeric multidimensional array
arrays, or other cell arrays. Unlike structures, you reshape Reshape array
access these cells by number. Use the cell array shiftdim Shift dimensions
functions to create and operate on these arrays. squeeze Remove singleton dimensions
sub2ind Single index from subscripts
Cell Array Functions
cell Create cell array Plotting and Data Visualization
cellfun Apply a function to each element
in a cell array This extensive set of functions gives you the ability
cellstr Create cell array of strings from to create basic graphs such as bar, pie, polar, and
character array three-dimensional plots, and advanced graphs
cell2struct Cell array to structure array such as surface, mesh, contour, and volume
conversion visualization plots. In addition, you can use these
celldisp Display cell array contents functions to control lighting, color, view, and many
other fine manipulations.
cellplot Graphically display the
structure of cell arrays
Basic Plots and Graphs
num2cell Convert a numeric array into a
cell array bar Vertical bar chart
barh Horizontal bar chart
Multidimensional Array Functions hist Plot histograms
hold Hold current graph
These functions provide a mechanism for working
loglog Plot using log-log scales
with arrays of dimension greater than 2.
pie Pie plot
plot Plot vectors or matrices.
polar Polar coordinate plot
semilogx Semi-log scale plot
16
Plotting and Data Visualization
Basic Plots and Graphs (Continued) Plot Annotation and Grids (Continued)
semilogy Semi-log scale plot ylabel Y-axis labels for 2-D and 3-D
subplot Create axes in tiled positions plots
zlabel Z-axis labels for 3-D plots
Three-Dimensional Plotting
bar3 Vertical 3-D bar chart Surface, Mesh, and Contour Plots
bar3h Horizontal 3-D bar chart contour Contour (level curves) plot
comet3 Three-dimensional comet plot contourc Contour computation
cylinder Generate cylinder contourf Filled contour plot
fill3 Draw filled 3-D polygons in hidden Mesh hidden line removal mode
3-space meshc Combination mesh/contourplot
plot3 Plot lines and points in 3-D mesh 3-D mesh with reference plane
space peaks A sample function of two
quiver3 Three-dimensional quiver (or variables
velocity) plot surf 3-D shaded surface graph
slice Volumetric slice plot surface Create surface low-level objects
sphere Generate sphere surfc Combination surf/contourplot
stem3 Plot discrete surface data surfl 3-D shaded surface with lighting
waterfall Waterfall plot trimesh Triangular mesh plot
trisurf Triangular surface plot
Plot Annotation and Grids
clabel Add contour labels to a contour Volume Visualization
plot
coneplot Plot velocity vectors as cones in
datetick Date formatted tick labels 3-D vector field
grid Grid lines for 2-D and 3-D plots contourslice Draw contours in volume slice
gtext Place text on a 2-D graph using plane
a mouse isocaps Compute isosurface end-cap
legend Graph legend for lines and geometry
patches isonormals Compute normals of isosurface
plotedit Start plot edit mode to edit and vertices
annotate plots isosurface Extract isosurface data from
plotyy Plot graphs with Y tick labels on volume data
the left and right reducepatch Reduce the number of patch
title Titles for 2-D and 3-D plots faces
xlabel X-axis labels for 2-D and 3-D reducevolume Reduce number of elements in
plots volume data set
shrinkfaces Reduce the size of patch faces
smooth3 Smooth 3-D data
17
MATLAB Quick Reference
18
Plotting and Data Visualization
19
MATLAB Quick Reference
20
Graphical User Interface Creation
Other Functions
dragrect Drag rectangles with mouse
gcbo Return handle of object whose
callback is executing
rbbox Create rubberband box for area
selection
selectmoveresize Select, move, resize, or copy axes
and uicontrol graphics objects
textwrap Return wrapped string matrix
for given uicontrol
uiresume Used with uiwait, controls
program execution
21
MATLAB Quick Reference
22