フィルターのクリア

get rid of e notation

6 ビュー (過去 30 日間)
Naveen Francis
Naveen Francis 2011 年 7 月 12 日
how do i get rid of the e notation in a variable? eg 4.321e+003, i just need it as 4321. its stopping me from plotting a graph.

採用された回答

Walter Roberson
Walter Roberson 2011 年 7 月 12 日
Sounds to me as if you have accidentally created a variable named "plot".
In the mean time, use round() on your data and see if you get a plot out. My guess is that you will not.
  7 件のコメント
Walter Roberson
Walter Roberson 2011 年 7 月 12 日
What is "a" ? If it is an array, then a(z) would be attempting to subscript "a" by the values in "z".
If "a" is an array and you are expecting that "z" will work out as integral, then you might be experiencing floating point roundoff limitations; if so then a(round(z)) should work (unless some z rounds to zero.)
Naveen Francis
Naveen Francis 2011 年 7 月 12 日
got it.:)

サインインしてコメントする。

その他の回答 (2 件)

Friedrich
Friedrich 2011 年 7 月 12 日
Hi,
have a look at the format function:
So this should work
format long
  1 件のコメント
Naveen Francis
Naveen Francis 2011 年 7 月 12 日
i tried that but it doesnt seem to work!

サインインしてコメントする。


Paulo Silva
Paulo Silva 2011 年 7 月 12 日
No it's not stopping you unless the variable is a string instead of a number, please provide more details.
  3 件のコメント
Naveen Francis
Naveen Francis 2011 年 7 月 12 日
i guess the 'e' in the number must be interpreted as a character by matlab which is why its giving me an error while plotting.
Paulo Silva
Paulo Silva 2011 年 7 月 12 日
something doesn't seem right, please provide the code and a sample of the data

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeLine Plots についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by