フィルターのクリア

Saving multiple figures of loop in one subplot

1 回表示 (過去 30 日間)
Ali
Ali 2019 年 2 月 18 日
コメント済み: Ali 2019 年 2 月 18 日
Is it possible to save figures of different loops in 1 sub plot?For example:there are 3 different training and testing datasets.I want to save the results of all three datasets in 1 subplot.Thank you.
Suppose dataset of 3 homes
data1 =Home 1;
date2=Home 2;
date3=Home 3;
i=data1+data2+data3;
for j=1:i
-----
end
% After training a model;
results_home1=actual Vs Predicted ; % suplot 1
results_home2=actual Vs Predicted ; % suplot 2
results_home3=actual Vs Predicted ; % suplot 3
% All the above suplots in 1 figure
  2 件のコメント
Geoff Hayes
Geoff Hayes 2019 年 2 月 18 日
Ali - do you want a subplot for each of the three data sets (results_home*), or one plot for all three? Please show us how you have generated the actual and predicted values for each dataset - do you call a function three times to generate this data, or something else?
Ali
Ali 2019 年 2 月 18 日
I am using 3 datesets of 3 different home and after that i am using this example .I want to save every home results in 1 subplot.Example is attached in figure.figure.png
clc
clear
load HomeAmeter22016
load HomeBmeter12016
load HomeCmeter12016

サインインしてコメントする。

採用された回答

KSSV
KSSV 2019 年 2 月 18 日
for i = 1:3
subplot(3,1,i)
plot(rand(10,1))
title(num2str(i))
end
  1 件のコメント
Ali
Ali 2019 年 2 月 18 日
@KSSV.....Thank you for this.I will try this.Besides ,i couldnt able to plot a time series data which shows cases on my Y-axis and moving time and date with x-axis.The sample of graph i want is attached.data (.xlsx) is also attached.I want to use coloumn 1 and coloumn 3 for plotting.sample_plot.png

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeData Distribution Plots についてさらに検索

製品


リリース

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by