How to insert shapes in Report Generator? I want to create a tree like structure and block diagram. How do I write code for drawing that?

1 visualización (últimos 30 días)
Hi, I want to insert shapes to make a tree like diagram or structure in my report. Is there any way to draw? How do write code for that?
Is there any API available for Report Generation as it is there for tables, images, etc?
It would be great even if you suggest any alternative. Thank you.

Respuestas (1)

Kausthub
Kausthub el 11 de Oct. de 2023
Hi Srushti Khatau,
I understand that you would like to create shapes in MATLAB Report Generator to make tree-like diagrams.
Unfortunately, there are no built-in APIs available to create shapes in MATLAB Report Generator, but there are APIs to add figures and images. A possible workaround would be to create an image or figure of the tree diagram and place it in the report.
You could create the tree diagram using “digraph” or treeplot” functions.
Later you can incorporate the tree diagram into the report using the “Image” or “Figure” functions.
Also, I have attached the script - “createShapes.m” - containing the workaround. You could refer to this for more clarity.
Hope this helps and solves your query regarding inserting shapes to create a tree like diagram using MATLAB Report Generator!

Community Treasure Hunt

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

Start Hunting!

Translated by