How to align table data to xlim/ylim values
1 回表示 (過去 30 日間)
古いコメントを表示
I try to plot volume column from my table, but it doesn't work when I set custom xlim/ylim properties
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/854460/image.png)
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
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/854465/image.png)
0 件のコメント
採用された回答
Voss
2022 年 1 月 6 日
Question: Do any of the first 45 Volumes have a value between 250 and 295?
2 件のコメント
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 Center および File Exchange で Lighting, Transparency, and Shading についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!