How to align table data to xlim/ylim values

2 次查看(过去 30 天)
I try to plot volume column from my table, but it doesn't work when I set custom xlim/ylim properties
figure
plot(Volume,'LineWidth',1)
title('Dam Capacity Curve')
grid on
xlim([0 45])
ylim([250 295])
ax = gca;
ax.YAxisLocation = 'right';
For some reason I get a blank plot

采纳的回答

Voss
Voss 2022-1-6
Question: Do any of the first 45 Volumes have a value between 250 and 295?
  2 个评论
KarolN
KarolN 2022-1-6
编辑:KarolN 2022-1-6
Hello. No, the volume layers are every 5 meters and there are 10 of them. That makes total length of 45 meters with the interval of 5. The height starts at 250, end at 295 and has interval also of 5. That makes 5x5 layer grids. I don't understand why the plot does not fit.
Voss
Voss 2022-1-6
The Volumes I see in the table start at -8506 and go down (become more negative) from there.
I'm not sure how the variable Volumes relates to the Volumes column of the table. I assume it's the same.
The values you describe sound more like the ContourLine column of the table. Maybe you want to plot that and/or the variables got messed up going between the table and the workspace variables.

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Lighting, Transparency, and Shading 的更多信息

产品


版本

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by