plot multiple graphs in same plot alligned
情報
この質問は閉じられています。 編集または回答するには再度開いてください。
古いコメントを表示
Hi everybody, I am creating multiple plots within a for loop but what I would like instead is to have just one plot with multiple lines (one created by each iteration of the for loop). Those plots share the same values for the x axis but different ranges for the y, so it would be really convenient to have them alligned on the same "line", given that I don't care about the absolute values on the y axis. Any suggestions is much appreciated!
4 件のコメント
Adam
2018 年 7 月 9 日
What exactly is the question? What is wrong with just plotting the data all on the same graph?
Daniel Blight
2018 年 7 月 9 日
By different ranges for the y values, do you mean they vary by the same amount but between different numbers (e.g one varies between 0 & 10 and another between 20 & 30) or that they vary by differing amounts (e.g one between 0 & 10 and another between 0 & 100) or by differing amounts and between different numbers?
Salvatore Lacava
2018 年 7 月 9 日
Adam
2018 年 7 月 9 日
You should always give an explicit axes handle to all plotting instructions, e.g.
hold( hAxes, 'on' );
plot( hAxes, xData, yData,... );
etc. Then if you want things on the same axes that is where they will appear.
回答 (1 件)
dpb
2018 年 7 月 9 日
Then standardize the y data before plotting each line in a consistent fashion -- one way would be as Answer_327905 Another alternative might be to use the z-score of
z=(x-mu)/sigma
Many other choices possible depending upon just what the data represent as to what might make most sense.
0 件のコメント
この質問は閉じられています。
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!