Plot Not showing all values
8 ビュー (過去 30 日間)
古いコメントを表示
Hi,
I have a couple arrays being created from a CSV file.
Here is my code:
Array=csvread('SampleV5.csv');
col1 = Array(1, :);
col2 = Array(2, :);
plot(col2, col1);
For some reason the plot shows some giant values on the Y axis, even though the max value in the csv is only ~100.
Any ideas?
1 件のコメント
dpb
2020 年 5 月 27 日
編集済み: dpb
2020 年 5 月 27 日
Yeah. There really is at least one giant value in there...
0.300224 0.400304 0.500255 0.600571 0.700721
0 0.01 0.02 0.03 0.04
992008
19.92
Above is a tiny portion of the spreadsheet. I put
=MAX(A1:BXQ1)
=MAX(A2:BXQ2)
in A3 and A4.
In MATLAB, use the alternate optional return index value to find where that value is located and you can then look in that area to see if you can spot what may have happened.
ADDENDUM:
I didn't go look, but this could be another case of missing the decimal point Walter pointed out on the x-value array as well...perhaps that's intended to be 0.992008 instead?
回答 (1 件)
Walter Roberson
2020 年 5 月 27 日
The max value of col2 is only about 20, but the maximum value of col1 is 992008
Near 210 the entries go like
21.4239 21.5239 216226 21.7212 21.8214
That suggests to me that you might have accidently omitted some decimal points in entering the data. It looks like every 25th entry that it is happening to.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!