Info

此问题已关闭。 请重新打开它进行编辑或回答。

Does anyone know how to format the numeric entries in a Table Reporter?

1 次查看(过去 30 天)
The following code generates a short pdf report containing a table of random numbers. I need to format the numeric entries. Any ideas?
import mlreportgen.report.*
import mlreportgen.dom.*
report = Report('tables');
%add 'table reporter' table.
obj.reporterTable = BaseTable(array2table(rand(4,3)));
add(report,obj.reporterTable);
rptview(report);

回答(1 个)

madhan ravi
madhan ravi 2018-11-16
Doesn‘t this help?
P.S - I don‘t have report generator.
I believe sprintf() with specific format should solve your problem.
  1 个评论
cmcnabb
cmcnabb 2018-11-17
I don't know how to access the individual table entries in order to apply the sprintf command. Can you edit the example code to show me where 'sprintf()' would be applied?

此问题已关闭。

Community Treasure Hunt

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

Start Hunting!

Translated by