Skip to content

Instantly share code, notes, and snippets.

@scajanus
Created June 27, 2012 12:43
Show Gist options
  • Select an option

  • Save scajanus/3003868 to your computer and use it in GitHub Desktop.

Select an option

Save scajanus/3003868 to your computer and use it in GitHub Desktop.
matlab plot
figure
set(gcf,'color','w') % valkoinen tausta
set(gcf, 'PaperUnits', 'centimeters'); % mitat senttimetrejä
set(gcf, 'PaperPosition', [0 0 12 12]) % kuvan koko
subplot(2,1,1)
plot(1:10, [1:10; 5.5:0.5:10])
ylabel('y-akseli (cm)')
xlabel('x-akseli (s)')
legend('eka', 'toka', 'Location', 'NorthWest')
subplot(2,1,2)
plot(1:10, [1:10; 5.5:0.5:10])
ylabel('y-akseli (cm)')
xlabel('x-akseli (s)')
legend('eka', 'toka', 'Location', 'NorthWest')
set(get(gcf, 'CurrentAxes'), 'Fontsize', 8)
print -depsc -r300 -painters esimerkkikuva
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment