411 REFERENCE · Wikibooks
Julia for MATLAB Users/Core Language/Graphics
Reference material by Wikibooks contributors. This retains its source identity and is not 411 news reporting.
Graphics
See Introducing Julia/Plotting for an overview of the plotting ecosystem in Julia.
__TOC__
2-D and 3-D Plots
Line Plots
plot 2-D line plot
plot3 3-D line plot
loglog Log-log scale plot
semilogx Semilogarithmic plot
semilogy Semilogarithmic plot
errorbar Line plot with error bars
fplot Plot expression or function
fplot3 3-D parametric curve plotter
fimplicit Plot implicit function
LineSpec Line specification
ColorSpec Color specification
Pie Charts, Bar Plots, and Histograms
bar Bar graph
bar3 Plot 3-D bar graph
barh Plot bar graph horizontally
bar3h Plot horizontal 3-D bar graph
histogram Histogram plot
histogram2 Bivariate histogram plot
morebins Increase number of histogram bins
fewerbins Decrease number of histogram bins
histcounts Histogram bin counts
histcounts2 Bivariate histogram bin counts
binscatter Binned scatter plot
rose Angle histogram plot
pareto Pareto chart
area Filled area 2-D plot
pie Pie chart
pie3 3-D pie chart
Discrete Data Plots
stem Plot discrete sequence data
stairs Stairstep graph
stem3 Plot 3-D discrete sequence data
scatter Scatter plot
scatter3 3-D scatter plot
spy Visualize sparsity pattern
plotmatrix Scatter plot matrix
heatmap Create heatmap chart
sortx Sort elements in heatmap row
sorty Sort elements in heatmap column
wordcloud Create word cloud chart from text data
geobubble Visualize data values at specific geographic locations
geolimits Set or query geographic limits
Polar Plots
polarplot Plot line in polar coordinates
polarscatter Scatter chart in polar coordinates
polarhistogram Histogram chart in polar coordinates
compass Plot arrows emanating from origin
ezpolar Easy-to-use polar coordinate plotter
rlim Set or query r-axis limits for polar axes
thetalim Set or query theta-axis limits for polar axes
rticks Set or query r-axis tick values
thetaticks Set or query theta-axis tick values
rticklabels Set or query r-axis tick labels
thetaticklabels Set or query theta-axis tick labels
rtickformat Specify r-axis tick label format
thetatickformat Specify theta-axis tick label format
rtickangle Rotate r-axis tick labels
polaraxes Create polar axes
Contour Plots
contour Contour plot of matrix
contourf Filled 2-D contour plot
contourc Low-level contour plot computation
contour3 3-D contour plot
contourslice Draw contours in volume slice planes
clabel Label contour plot elevation
fcontour Plot contours
Vector Fields
feather Plot velocity vectors
quiver Quiver or velocity plot
compass Plot arrows emanating from origin
quiver3 3-D quiver or velocity plot
streamslice Plot streamlines in slice planes
streamline Plot streamlines from 2-D or 3-D vector data
Surfaces, Volumes, and Polygons
Surface and Mesh Plots
surf Surface plot
surfc Contour plot under a 3-D shaded surface plot
surface Create surface object
surfl Surface plot with colormap-based lighting
surfnorm Compute and display 3-D surface normals
mesh Mesh plot
meshc Plot a contour graph under mesh graph
meshz Plot a curtain around mesh plot
hidden Remove hidden lines from mesh plot
fsurf Plot 3-D surface
fmesh Plot 3-D mesh
fimplicit3 Plot 3-D implicit function
waterfall Waterfall plot
ribbon Ribbon plot
contour3 3-D contour plot
peaks Example function of two variables
cylinder Generate cylinder
ellipsoid Generate ellipsoid
sphere Generate sphere
pcolor Pseudocolor (checkerboard) plot
surf2patch Convert surface data to patch data
Volume Visualization
contourslice Draw contours in volume slice planes
flow Simple function of three variables
isocaps Compute isosurface end-cap geometry
isocolors Calculate isosurface and patch colors
isonormals Compute normals of isosurface vertices
isosurface Extract isosurface data from volume data
reducepatch Reduce number of patch faces
reducevolume Reduce number of elements in volume data set
shrinkfaces Reduce size of patch faces
slice Volume slice planes
smooth3 Smooth 3-D data
subvolume Extract subset of volume data set
volumebounds Coordinate and color limits for volume data
coneplot Plot velocity vectors as cones in 3-D vector field
curl Compute curl and angular velocity of vector field
divergence Compute divergence of vector field
interpstreamspeed Interpolate stream-line vertices from flow speed
stream2 Compute 2-D streamline data
stream3 Compute 3-D streamline data
streamline Plot streamlines from 2-D or 3-D vector data
streamparticles Plot stream particles
streamribbon 3-D stream ribbon plot from vector volume data
streamslice Plot streamlines in slice planes
streamtube Create 3-D stream tube plot
Polygons
fill Filled 2-D polygons
fill3 Filled 3-D polygons
patch Create one or more filled polygons
surf2patch Convert surface data to patch data
Animation
movie Play recorded movie frames
getframe Capture axes or figure as movie frame
frame2im Return image data associated with movie frame
im2frame Convert image to movie frame
animatedline Create animated line
addpoints Add points to animated line
getpoints Return points that define animated line
clearpoints Clear points from animated line
comet 2-D comet plot
comet3 3-D comet plot
drawnow Update figures and process callbacks
refreshdata Refresh data in graph when data source is specified
Formatting and Annotation
Titles and Labels
title Add title
xlabel Label x-axis
ylabel Label y-axis
zlabel Label z-axis
clabel Label contour plot elevation
legend Add legend to axes
colorbar Colorbar showing color scale
text Add text descriptions to data points
texlabel Format text with TeX characters
gtext Add text to figure using mouse
line Create primitive line
rectangle Create rectangle with sharp or curved corners
annotation Create annotations
Axes Appearance
xlim Set or query x-axis limits
ylim Set or query y-axis limits
zlim Set or query z-axis limits
axis Set axis limits and aspect ratios
box Display axes outline
daspect Control data unit length along each axis
pbaspect Control relative lengths of each axis
grid Display or hide axes grid lines
xticks Set or query x-axis tick values
yticks Set or query y-axis tick values
zticks Set or query z-axis tick values
xticklabels Set or query x-axis tick labels
yticklabels Set or query y-axis tick labels
zticklabels Set or query z-axis tick labels
xtickformat Specify x-axis tick label format
ytickformat Specify y-axis tick label format
ztickformat Specify z-axis tick label format
xtickangle Rotate x-axis tick labels
ytickangle Rotate y-axis tick labels
ztickangle Rotate z-axis tick labels
datetick Date formatted tick labels
ruler2num Convert data from specific ruler to numeric data
num2ruler Convert numeric data for use with specific ruler
hold Retain current plot when adding new plots
subplot Create axes in tiled positions
yyaxis Create chart with two y-axes
cla Clear axes
axes Create Cartesian axes
figure Create figure window
Colormaps
colormap View and set current colormap
colorbar Colorbar showing color scale
rgbplot Plot colormap
Colormap Editor Open colormap editor
brighten Brighten or darken colormap
contrast Create grayscale colormap to enhance image contrast
caxis Set colormap limits
spinmap Rotate colormap colors
hsv2rgb Convert HSV colors to RGB
rgb2hsv Convert RGB colors to HSV
parula Parula colormap array
jet Jet colormap array
hsv HSV colormap array
hot Hot colormap array
cool Cool colormap array
spring Spring colormap array
summer Summer colormap array
autumn Autumn colormap array
winter Winter colormap array
gray Gray colormap array
bone Bone colormap array
copper Copper colormap array
pink Pink colormap array
lines Lines colormap array
colorcube Colorcube colormap array
prism Prism colormap array
flag Flag colormap array
3-D Scene Control
Camera Views
view Viewpoint specification
makehgtform Create 4-by-4 transform matrix
viewmtx View transformation matrices
cameratoolbar Control camera toolbar programmatically
campan Rotate camera target around camera position
camzoom Zoom in and out on scene
camdolly Move camera position and target
camlookat Position camera to view object or group of objects
camorbit Rotate camera position around camera target
campos Set or query camera position
camproj Set or query projection type
camroll Rotate camera about view axis
camtarget Set or query location of camera target
camup Set or query camera up vector
camva Set or query camera view angle
Lighting, Transparency, and Shading
camlight Create or move light object in camera coordinates
light Create light
lightangle Create or position light object in spherical coordinates
lighting Specify lighting algorithm
shading Set color shading properties
diffuse Calculate diffuse reflectance
material Control reflectance properties of surfaces and patches
specular Calculate specular reflectance
alim Set or query axes alpha limits
alpha Add transparency to objects in axes
alphamap Specify figure alphamap (transparency)
Images
imshow Display image
image Display image from array
imagesc Display image with scaled colors
imread Read image from graphics file
imresize Resize image
imwrite Write image to graphics file
imfinfo Information about graphics file
imformats Manage image file format registry
frame2im Return image data associated with movie frame
im2frame Convert image to movie frame
im2java Convert image to Java image
im2double Convert image to double precision
ind2rgb Convert indexed image to RGB image
rgb2gray Convert RGB image or colormap to grayscale
rgb2ind Convert RGB image to indexed image
imapprox Approximate indexed image by reducing number of colors
dither Convert image, increasing apparent color resolution by dithering
cmpermute Rearrange colors in colormap