how to plot graph

2 ビュー (過去 30 日間)
Raheema Syed
Raheema Syed 2019 年 2 月 8 日
回答済み: Star Strider 2019 年 2 月 8 日
Suppose i have a result,
result = 1 2 3 4
5 6 7 8
9 10 11 12
where in this 3x4 matrix, the 3 rows denote 3 different generator and 4 coloumns denote time period in four hours.
how to plot a graph for time vs the generation. that is in x-axis you will have 4 hrs time period with 1 hr difference and y axis will be generation takin into account the 3 different generator values for each hour.
The above one is for example purpose. I need to plot for 6 generating units for 12 hours.

回答 (1 件)

Star Strider
Star Strider 2019 年 2 月 8 日
result = [1 2 3 4
5 6 7 8
9 10 11 12];
time = [1 2 3 4];
figure
plot(time, result)

カテゴリ

Help Center および File Exchange2-D and 3-D Plots についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by