In App Designer, how can I ensure that the values displayed on the UI do not appear in scientific notation?
9 ビュー (過去 30 日間)
古いコメントを表示
For example, I have a field called app.Profile.Value. Large numbers are often converted to scientific notation. How do I force all values of this variable to be displayed properly, i.e., 1234, instead of 1.234*10^3?
0 件のコメント
採用された回答
Image Analyst
2025 年 7 月 2 日
編集済み: Image Analyst
2025 年 7 月 2 日
Where or how are you displaying them? If you're using fprintf or sprintf, use %.3f or %g in your format specifier. If you're just having them echo to the command window, try
> format longg
5 件のコメント
Image Analyst
2025 年 7 月 7 日
Change the ValueDisplayFormat string to %.4f instead of %.4g. If you want integers, use %.0f but that will display integers but the underlying number will still be floating point. You can check the RoundFractionalValues if you want the underlying values to also be integers.

その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Develop Apps Using App Designer についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!