Apply grid for figure
Mostrar comentarios más antiguos
Dear
I want to apply grid for 4 parts of the regression figure and I use this code
nntraintool('plot','plotregression')
set(findall(gcf,'-property','FontSize'),'FontSize',10)
grid on;
But only grid appear in the last figure (the forth figure I marked with yellow color). Could you help me ? Many thank

3 comentarios
Bjorn Gustavsson
el 25 de Abr. de 2020
grid on only set the grid to the current axes. To get grid.lines in all subplots you need to make each of the subplots current axes, typically something like this gets the job done:
for i1 = 1:4
subplot(2,2,i1)
grid on
end
However, sometimes when much decorations (adding of colorbars) have been made to an axes so that its position have changed from the default this can delete the subplot and create a default-located emty subplot with grid-lines. If that happens you might get away by manually making each subplot current and then manually call grid on.
HTH
Tran Hoa
el 26 de Abr. de 2020
Pratik Bajaria
el 14 de Abr. de 2021
Respuestas (0)
Categorías
Más información sobre Subplots en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!