Info

この質問は閉じられています。 編集または回答するには再度開いてください。

how do i print the 10 figures seprately ?

1 回表示 (過去 30 日間)
STUDENT
STUDENT 2019 年 10 月 23 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
clear;clc
M = rand(1000,10);
M = cos(2*pi*M);
for c = 1:size(M,2)
figure(c)
hist(M(:,c))
title(num2str(c))10')
% print images to file e.g. 1.png to 10.png
end
csvwrite('randomData.csv',M)

回答 (1 件)

Shubham Gupta
Shubham Gupta 2019 年 10 月 24 日
Try:
clear;clc
M = rand(1000,10);
M = cos(2*pi*M);
for c = 1:size(M,2)
figure(c)
hist(M(:,c))
title(num2str(c))
print(num2str(c),'-dpng')
end
csvwrite('randomData.csv',M)
Hope it helps !

タグ

製品


リリース

R2019a

Community Treasure Hunt

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

Start Hunting!

Translated by