how to include the simulation result graph image (obtained from GUI) into the Report Generator Code?

1 vue (au cours des 30 derniers jours)
I obtain my Simulation RESULT after each calculation using the Designed GUI.
and I want to obtain a PDF report which includes this simulation result (as a part of the report) image at the end.
Kindly help me out with a detailed sample code.
  2 commentaires
poornima tumkur nataraj
poornima tumkur nataraj le 9 Nov 2021
Thank you for your comment.@Geoff Hayes.
Actually, the report I am creating also has components like paragraphs, tables & texts. This simulation result is just a part of the report. So I am not sure, in which part of the report code can I include the code of for publishing the simulatiom result.
Right now, my code looks basic like this.
Could you please suggest me, HOW & in which part of the code can I include the code for sim result?
import mlreportgen.report.*
import mlreportgen.dom.*
rpt = Report('output','pdf');
tp = TitlePage();
title = Paragraph(' Tests');
title.Style = {HAlign('left'),FontFamily('Arial'),...
FontSize('24pt'),Color('white'),...
BackgroundColor('blue'),...
OuterMargin('0in','0in','.5in','1in'),...
HAlign('center')};
tp.Title = title;
tp.Subtitle = 'Monthly Data';
tp.Image = which('image.jpg');
tp.Author = 'John Smith';
tp.Publisher = 'MathWorks';
tp.PubDate = date();
% here i WANT TO INCLUDE A TABLE AND THEN THE SIM RESULTS
add(rpt, tp);
close(rpt);
rptview(rpt);

Connectez-vous pour commenter.

Réponses (1)

Srijith Kasaragod
Srijith Kasaragod le 22 Nov 2021
Hi,
One way you could add simulation images to a report is to have the figure saved locally and use 'append' function.
Hope this helps!

Produits


Version

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by