Multiple Plot and saving as jpg

Answers (1)

Hi,
here's a piece of code that should get you started.
Best
Michael
clear all; close all; clc;
% Create the Figures (this part you already have in your code somewhere)
for i=1:1:3
figure
h(i) = plot(rand(10,1));
end
% Save the Figures as jpeg using the Graphics handle h(i)
for i=1:1:numel(h)
saveas(h(i),sprintf('%d.jpg', i))
end

Categories

Find more on Creating, Deleting, and Querying Graphics Objects in Help Center and File Exchange

Products

Asked:

on 28 Jul 2016

Answered:

on 28 Jul 2016

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!