How to format data in table?

I have a function that opens a figure and prints data to a table. The numbers are formatted in scientific notation, how can I change that? I tried format ShortG but it doesn't affect the table. Thank you!

3 Kommentare

Jan
Jan am 5 Nov. 2011
Do you mean a UITABLE? Which format do you want? Can you convert the data using SPRINTF or NUM2STR to strings?
Walter Roberson
Walter Roberson am 5 Nov. 2011
The "format" command *only* affects disp() and display() .
Brian
Brian am 6 Nov. 2011
Yes, it is a UITABLE. I just want in regular numbers, e.g. 1437.5 not 1.4375e+03

Melden Sie sich an, um zu kommentieren.

 Akzeptierte Antwort

Walter Roberson
Walter Roberson am 6 Nov. 2011

0 Stimmen

There is no provision to do that in uitable(). When you indicate the format for the column in uitable(), then the only supported alternate format available for numeric entries is 'bank'.
The alternative is to store your entries as character strings.

Weitere Antworten (0)

Kategorien

Community Treasure Hunt

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

Start Hunting!

Translated by