Reputation: 1708
See the documentation:
grid on
and grid off
, you can show or hide a major grid.grid minor
, you toggle the visibility of the minor grid lines. This means that if a plot script containing grid minor
is run multiple times, the minor grid will be shown or hidden depending on whether it was run an odd or even number of times. Is there a way to always show the minor grid, so without toggling? Something like grid minor on
.Upvotes: 0
Views: 8581
Reputation: 1358
You can set the XMinorGrid
, YMinorGrid
and ZMinorGrid
properties of your axes to 'on'
.
surf(peaks)
set(gca,'XMinorGrid','on');
set(gca,'YMinorGrid','on');
set(gca,'ZMinorGrid','on');
Upvotes: 2