How can I make uitable show me acutal values instead of class/type of variable?
4 views (last 30 days)
Show older comments
Hello,
I'm trying to save the output table of a ranova as a jpeg file using uitable. It works partially. However, the second part of the table is converted into type of variable, so that it yields "1x1 double" instead of the actual values. Doing it column after column results in the same output.
Where is my problem, what could I change?
Thanks in advance!
clear fig h uit
close all
fig = uifigure;
uit = uitable(fig,"Data",RMA{7,1});
h=uit();
h.Position=[1,41,1536,500];
fig.WindowState='maximized'
exportapp(fig,'RMA7fig.jpeg')
0 Comments
Accepted Answer
Voss
on 1 Apr 2024
I guess RMA{7,1} is the table returned from ranova, in which case you can try:
T = RMA{1,7};
T = convertvars(T,1:width(T),'double');
uit = uitable(fig,"Data",T);
which uses convertvars to convert all table variables to doubles (the ones showing up as "1x1 double" may have been of class internal.stats.DoubleTableColumn).
More Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!