Skip to content

Instantly share code, notes, and snippets.

@mightbxg
Created December 22, 2022 06:05
Show Gist options
  • Save mightbxg/253ebd50af1ac6324ea5783ec3c7148c to your computer and use it in GitHub Desktop.
Save mightbxg/253ebd50af1ac6324ea5783ec3c7148c to your computer and use it in GitHub Desktop.
modify figures in matlab
%% get axes handles
ax_hdls = findobj(groot, 'type', 'axes');
ax_1 = ax_hdls(1);
ax_2 = ax_hdls(2);
% set Y limits
set([ax_1, ax_2], 'YLim', pitch_range);
% plot
plot(ax_1, x, y);
% set window property
set(findobj(groot, 'type', 'figure'), 'WindowState', 'maximized');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment