ax.XGrid = 'on'
is setting the property XGrid
of the current axes (ax
) to 'on'
. This turns on the grid lines for the x-axis.
In MATLAB, the grid lines can help the viewer to make a better sense of the data plotted on the axes.
Here's an example code:
main.m75 chars6 lines
The above code plots a sine curve and turns on the grid lines for the x-axis.
gistlibby LogSnag