MATLAB: How to publish the Command Window output to a report

commandevalcgeneratorMATLABoutputparagraphreportwindow

Can you help me figure out how to direct my command window output into the report? I basically want the output of the current run to be printed to the report.

Best Answer

To capture output from the MATLAB Command Window, use the "evalc" function:
You can then put your saved output as a Paragraph object and "append" that to your Report: