Generated banner for Matlab Generate Report
Generated logo for Matlab Generate Report

Matlab Generate Report

MathWorksOfficialCreated by MathWorks

  • Skill
  • Tool integration
  • Science and research
  • BSD-2-Clause
  • No issues found

From the author

Unified skill for all MATLAB and Simulink report generation tasks. Covers report generation, PDF report, document generation, mlreportgen, Report Generator, template, TitlePage, Chapter, multipage HTML, HTMLPage, html-multipage, custom reporter, customizeReporter, template hole, page header, page border, company style package, branded reporters, buildTemplates, Simulink report, model documentation, slreportgen, block diagram report, model report, subsystem documentation, SystemDiagramFinder, SystemIO, ExecutionOrder, LookupTable, template style, page footer, TemplateSrc, report package, table variants, multiple HTML pages, PDF report generation, Word report, DOM API, FormalTable, BaseTable, Figure, FormalImage, Section.
— the description by MathWorks

AutoGineer summary

Written by AutoGineer from the skill’s own files, not by the author

The MATLAB Report Generation skill provides a unified framework for creating structured, professional documentation directly from MATLAB and Simulink. It leverages the Report API for high-level document structure and the DOM API for granular control over formatting, tables, and images. The system supports template-based styling, custom reporter classes for branded content, and specialized tools for documenting Simulink models, including block diagrams and execution order.

What it does

  • Creates PDF, Word, and HTML documents from MATLAB data.
  • Supports auto-numbered figures, tables, and chapters.
  • Generates technical documentation for Simulink models.
  • Enables custom branded templates with headers, footers, and page borders.
  • Provides a scaffolded approach for building custom reporter classes.
  • Supports multipage HTML output with navigation.

When to use it

  • When you need to automate the creation of technical reports from MATLAB analysis.
  • When documenting Simulink models, including system I/O and execution order.
  • When you require consistent, branded document styling across multiple reports.
  • When you need to integrate MATLAB plots and data into professional PDF or Word documents.

Advantages

  • Maintains document structure and numbering automatically.
  • Separates content logic from visual styling via templates.
  • Provides specialized support for complex Simulink model documentation.
  • Allows for highly customized, reusable report components.

Usage examples

“Create a basic PDF report with a title page and a chapter containing a plot.”
The agent provides a script using mlreportgen.report.Report, TitlePage, and Figure classes to generate a PDF with auto-numbered content.
“How do I document a Simulink model's system I/O?”
The agent guides you to use slreportgen.report.Report and the SystemIO reporter to extract and format model I/O data.
“How can I create a custom report template?”
The agent instructs you to use the customizeReporter method to scaffold a custom reporter class and its associated template files.

Install

  1. Download the skill as a ZIP:

    https://autogineer.com/agent-skills/matlab/matlab-generate-report/download
  2. Unzip it into the cross-client skills folder of your project:

    mkdir -p .agents/skills && unzip matlab-generate-report.zip -d .agents/skills

Documentation by MathWorks

MATLAB Report Generation

Generate structured, professional reports (PDF, Word, HTML) from MATLAB data and Simulink models.

When to Use

  • Creating PDF, Word, or HTML reports from MATLAB data

  • Building reports with chapters, title pages, tables of contents

  • Adding auto-numbered figures and tables to documents

  • Creating multipage HTML reports (separate HTML files with navigation)

  • Documenting Simulink models with block diagrams, I/O tables, execution order

  • Customizing report templates (styles, colors, fonts, headers, footers)

  • Creating custom reporter classes with template holes and dynamic content

  • Building multi-reporter packages with shared company styles

  • Creating table variant reporters with different header colors

  • Including HTML content in reports

When NOT to Use

  • Simple file export (CSV, Excel) — use writetable, writematrix

  • Live Scripts as reports — use MATLAB Live Editor export

  • Interactive report building — use Report Explorer GUI

  • Web views of Simulink models — use slreportgen.webview.* directly

API Selection

Always use the Report API (mlreportgen.report.*) as the foundation. It provides the Report container and reporters (Figure, BaseTable, FormalImage, Chapter, TitlePage, etc.) that handle auto-numbering, captions, and document structure.

Use both APIs together. Use the Report API to create the report and add content for which reporters exist. Use the DOM API (mlreportgen.dom.*) for styled paragraphs, custom tables, inline formatting, HTML inclusion, and images without captions. DOM objects append directly to Report, Chapter, or Section alongside reporters.

Critical rule: Report API reporters (Figure, BaseTable, FormalImage) can ONLY be appended to Report, Chapter, or Section objects — never to DOM objects like TableEntry. Use DOM objects inside TableEntry.

Simulink reports: Use slreportgen.report.Report (not mlreportgen.report.Report) — it extends the base with model compilation support required by SystemIO, ExecutionOrder, and other Simulink reporters.

Multipage HTML: Use mlreportgen.dom.Document with "html-multipage" type + HTMLPage objects. This is the only case where you use the DOM Document instead of the Report API Report.

Core Workflow: Standard Report

TitlePage, TableOfContents, ListOfFigures, and ListOfTables are optional — include only when the task requires them. The minimal report is just Report + content + close.

import mlreportgen.report.*
import mlreportgen.dom.*

rpt = Report("MyReport","pdf");
append(rpt,TitlePage(Title="Report Title",Author="Team"));  % optional
append(rpt,TableOfContents());   % optional
append(rpt,ListOfFigures());     % optional
append(rpt,ListOfTables());      % optional

ch = Chapter("Results");
append(ch,Paragraph("Analysis complete."));

% Auto-numbered table
data = FormalTable(["ID","Value"],[1 10; 2 20]);
bt = BaseTable(data);
bt.Title = "Measured values";
append(ch,bt);

% Auto-numbered figure
fig = figure("Visible","off");
plot([1 2],[10 20]);
rptFig = Figure(fig);
rptFig.Snapshot.Caption = "Value trend";
append(ch,rptFig);
close(fig);

append(rpt,ch);
close(rpt);
rptview(rpt);
load_system(modelName);

% MUST use slreportgen.report.Report for Simulink content
rpt = slreportgen.report.Report(outputPath,"pdf");
append(rpt,mlreportgen.report.TitlePage("Title","Model Report"));
append(rpt,mlreportgen.report.TableOfContents());

ch = mlreportgen.report.Chapter("Diagrams");

% Root diagram — direct reporter
rootDiag = slreportgen.report.Diagram(modelName);
rootDiag.Snapshot.ScaleToFit = true;
append(ch,rootDiag);

% Subsystems — finder pattern (iterator for memory efficiency)
finder = slreportgen.finder.SystemDiagramFinder(modelName);
finder.IncludeRoot = false;
finder.SortType = "alphabetical";

while finder.hasNext()
    result = finder.next();
    sec = mlreportgen.report.Section("Title",result.Name);
    append(sec,result);
    append(ch,sec);
end

append(rpt,ch);
close(rpt);
rptview(rpt);

Choosing Built-In vs Custom Reporters

Before writing code, analyze requirements against built-in reporter capabilities:

  1. List all content/format requirements — title page fields, page borders, headers/footers, branded styling

  2. Check built-in reporters. Built-in TitlePage has: Title, Subtitle, Author, Publisher, PubDate, Image. Built-in Chapter/Section provide headings, auto-numbering, and a Content hole.

  3. If built-in reporters meet all requirements, use them directly

  4. If any requirement is unmet, create custom reporters:

Common triggers for custom reporters:

  • Title page needs fields beyond the standard set (project name, facility, contract number)

  • Page borders, watermarks, or custom page layout

  • Page headers/footers with dynamic content (per-chapter images, tickers)

  • Branded table variants with different header colors

  • MATLAB-generated logos (geometric shapes drawn with plot/patch + exportgraphics)

Do NOT force-fit requirements into built-in properties (e.g., concatenating fields into Subtitle). Create a custom reporter instead.

Do NOT build custom title pages with raw DOM elements (Paragraphs, Images appended to a Chapter). Always use customizeReporter for template-based layout and format portability.

Decision Tree: What Reference Do I Need?

I need to...Reference
Build a standard report with chapters, figures, tables, verificationreferences/report-api-patterns.md
Work with DOM tables, HTML inclusion, multipage HTML, Number/NumberFormatreferences/dom-api-patterns.md
Understand template file types, locate/inspect templatesreferences/template-system.md
Look up built-in template holes, styles, page layout (pre-computed)references/template-reference.md
Create a custom reporter class (customizeReporter, holes, headers)references/custom-reporters.md
Build a multi-reporter package with shared styles and buildTemplatesreferences/report-package.md
Generate Simulink model reports (finders, orientation, centering)references/simulink-report.md
Look up all Simulink finders and reportersreferences/finders-and-reporters.md
Iterate struct arrays into chapters with custom reportersreferences/data-driven-report-pattern.md
Edit template styles (colors, fonts, headers, footers, TOC)references/template-system.md

Key Functions

ClassPurposePackage
ReportTop-level report containermlreportgen.report
TitlePageTitle page with title, subtitle, authormlreportgen.report
TableOfContentsAuto-generated TOCmlreportgen.report
Chapter / SectionDocument structuremlreportgen.report
FigureAuto-numbered figure from MATLAB figuremlreportgen.report
FormalImageAuto-numbered image from file with captionmlreportgen.report
BaseTableAuto-numbered table wrapper (pass FormalTable)mlreportgen.report
FormalTableTable with header/body/footer from cell arraysmlreportgen.dom
Template (3-arg)Edit templates: Template(out,fmt,src)mlreportgen.dom
HTMLFile / HTMLInclude HTML content in any output formatmlreportgen.dom
HTMLPagePage in multipage HTML document (R2024a+)mlreportgen.dom
NumberNumeric DOM object (use with NumberFormat)mlreportgen.dom
TemplateHolePlaceholder filled at report timemlreportgen.dom
Page / NumPagesPage number / total pagesmlreportgen.dom
*.customizeReporterScaffold custom reporter + templatesmlreportgen.report
getStyle / replaceStyleModify template stylesmlreportgen.dom
slreportgen.report.ReportReport container for Simulink contentslreportgen.report
slreportgen.report.DiagramDiagram snapshot of a systemslreportgen.report
slreportgen.finder.SystemDiagramFinderFind system/subsystem diagramsslreportgen.finder
slreportgen.report.SystemIOReport inputs/outputs (requires compilation)slreportgen.report
slreportgen.report.ExecutionOrderReport block execution orderslreportgen.report
slreportgen.report.LookupTableReport lookup table data + plotslreportgen.report
rptviewDisplay report (updates DOCX fields)function
docviewProcess Word documents (update fields, convert)function

Common Mistakes

MistakeCorrect Approach
Using mlreportgen.dom.Document as report containerUse mlreportgen.report.Report. Exception: multipage HTML requires Document with "html-multipage"
Using mlreportgen.report.Report for Simulink contentUse slreportgen.report.Report — needed for model compilation
Using Report with "html" for multipage outputUse mlreportgen.dom.Document with "html-multipage" + HTMLPage objects
Appending reporters to DOM objects (Paragraph, TableEntry)Reporters can ONLY go in Report, Chapter, or Section. Use DOM objects inside TableEntry
Putting raw doubles in FormalTable cellsUse Number with NumberFormat in Style: n = Number(42); n.Style = {NumberFormat("%.0f")}. Put n directly in cell arrays. See references/dom-api-patterns.md § Number and NumberFormat
NumberFormat("$%.0f") or NumberFormat("%,.0f")Only standard sprintf specifiers work (no $, no %,, no %d). For currency/units, wrap Number in Paragraph and prepend/append Text
Customizing only "default"/"even" page headersCustomize ALL page types: "first", "default", "even" — but differentiate content (see below)
Putting StyleRef (chapter title) in the first-page headerFirst page already displays the chapter heading — omit StyleRef from "first" header. Use it only in "default"/"even" for wayfinding
Opening DOCX with winopen/open/startUse rptview(rpt) or docview(file,"updatefields") — triggers field update
Using ColSpec/ColSpecGroup for widthsUse TableColSpecGroup + TableColSpec with Width in Style
Setting widths without ResizeToFitContents(false)Add ResizeToFitContents(false) to table Style; set absolute ft.Width (not "100%")
TemplateParagraphStyle.Formats = {Bold(true)}Use array: Formats = [Bold(true),FontSize("12pt")]
Template(path,"pdf") to edit existing template2-arg creates blank. Use 3-arg: Template(out,"pdf",src)
Same path for source and output in Template constructorOPC cannot read/write simultaneously. Use different paths, then movefile
Setting PDFPageLayout.PageSize.Orientation without rotate()Call rotate(pl) — swaps Width/Height AND sets Orientation
Using DOCXPageLayout without explicit Height and WidthDOCX does not auto-swap — set both explicitly
Page numbers resetting after PDFPageLayoutSet pl.FirstPageNumber = '' (empty string) to continue numbering
Wrapping reporter in Paragraph to center itCustomize the reporter's template style via Template API
Using RawText(html) for HTML in PDFUse HTMLFile(path) or HTML(string) — works for any format
Using Group in a Table cell arrayUse nested cell arrays: Table({{img,caption},desc})
Passing MATLAB table() to BaseTablePass FormalTable(headers,body) — avoids MATLABTable wrapper
e.Style = {BackgroundColor("yellow")} (overwrites existing styles)Append: e.Style = [e.Style, {BackgroundColor("yellow")}] — preserves inherited styles
Force-fitting fields into TitlePage.SubtitleCreate a custom title page reporter via customizeReporter
Writing custom reporter class from scratchUse customizeReporter to scaffold — creates required binary templates
Writing classdef before running customizeReporterScaffolding overwrites classdef files. Scaffold first, then edit
Unqualified TitlePage.getClassFolder() in packageUse fully-qualified: mypkg.TitlePage.getClassFolder()
getStyle(ss,name,type) for PDF/HTMLType arg returns []. Use getStyle(ss,name) without type
OuterMargin("12pt","6pt","0","0") for vertical spacingArgs are (left,right,top,bottom) — NOT CSS order. Use OuterMargin("0","0","12pt","6pt") for top/bottom spacing
Using TemplateCharacterStyleDoes not exist. Use TemplateTextStyle for character/inline styles in PDF/HTML
Unzipping .pdftx/.htmtx/.dotx to edit with fileread/regexprepALWAYS use DOM Template API — Template(out,fmt,src) + open + modify objects + close. Raw edits bypass framework validation
find_system + DiagramFinder for discoveryUse SystemDiagramFinder with filter properties
Diagram(result.Path) on ChartDiagramFinder resultsUse getReporter(result) — chart paths are invalid for Diagram constructor
find() + for loop on findersAlways use iterator: while finder.hasNext() / result = finder.next()
BlockFinder with SearchDepth=inf expecting referenced modelsBlockFinder does NOT traverse Model References. Use SystemDiagramFinder (IncludeReferencedModels=true) + per-system BlockFinder (SearchDepth=1)
ExecutionOrder on virtual subsystemCheck get_param(obj,'IsSubsystemVirtual') first
ExecutionOrder/SystemIO on Simulink FunctionsGuard with slreportgen.utils.isSimulinkFunction(result.Object)

Conventions

  • Always close(rpt) after appending all content — generates the output file

  • Always rptview or docview to open DOCX — never winopen or open

  • Use figure("Visible","off") for plots destined for reports

  • Use exportgraphics (not print) when saving figures to files

  • One Chapter = one numbering scope — figures/tables numbered Chapter-Sequence (e.g., "Figure 2-1")

  • BaseTable wraps FormalTable — pass FormalTable(headers,body), not a MATLAB table()

  • Cell-level styling: Use entry(t,row,col) after construction, not during

  • Template styles use [] arrays; inline .Style properties use {}

  • Reporters in @ClassName directories — each needs its own resources/templates/

  • Scaffold ALL reporters before editing ANY — customizeReporter creates binary templates + overwrites classdef

  • Fix unqualified class names after scaffolding — use package-qualified names

  • Customize all output formats — PDF/Word/HTML templates are independent

  • Simulink: Always slreportgen.report.Report; always Diagram.Snapshot.ScaleToFit = true

  • Simulink finders: Use .Object handle (not path string) for get_param; use result.Name for titles

  • JSON is single source of truth for multi-reporter packages — never hardcode style values

Viewing and Processing Reports

rptview(rpt);                           % Open in system viewer (updates DOCX fields)
rptview("MyReport.docx","pdf");         % Convert DOCX to PDF via Word
docview("Report.docx","updatefields","closedoc","closeapp");  % Update without display

Verification: Running without error does NOT confirm correctness. After close(rpt):

  • Check isfile(rpt.OutputPath) and dir(rpt.OutputPath).bytes > 1000

  • For PDF: call open(rpt), then set rpt.Document.RetainFO = true before appending content, search *_FO/*.fo files

  • For DOCX: unzip and search word/document.xml

  • Assert expected titles, headings, captions appear in output

See references/report-api-patterns.md for full verification patterns.

Required Toolbox

MATLAB Report Generator (verify with mcp__matlab__detect_matlab_toolboxes). Simulink Report Generator additionally required for Simulink model reports.


Copyright 2026 The MathWorks, Inc.


Files

references/template-reference.md

Reporter Template Reference

Pre-computed introspection of common MATLAB Report Generator reporter templates.

Note: This covers frequently customized built-in reporters only. For Simulink reporters, custom reporters, or any reporter not listed here, use the introspection technique described in template-system.md.


TitlePage Reporter

Properties
PropertyDefaultPurpose
Title—Title text
Subtitle—Subtitle text
Image—Cover image
Author—Author name
Publisher—Publisher name
PubDate—Publication date
DOCX Template (.dotx)
Holes (6)
Hole AliasPlaceholderMaps to Property
TitleTITLEtp.Title
SubtitleSUBTITLEtp.Subtitle
ImageIMAGEtp.Image
AuthorAUTHORtp.Author
PublisherPUBLISHERtp.Publisher
PubDatePUB_DATEtp.PubDate
Styles
Style IDFont SizeBoldAlignmentSpace Before
TitlePageTitle24pt (48 half-pts)YesCenter380 twips
TitlePageSubtitle20pt (40 half-pts)YesCenter320 twips
TitlePageImage18pt (36 half-pts)YesCenter220 twips
TitlePageAuthor18pt (36 half-pts)YesCenter220 twips
TitlePagePublisher10pt (20 half-pts)NoCenter200 twips
TitlePagePubDate10pt (20 half-pts)NoCenter200 twips

All styles: line=240 (single), after=0. Base: Calibri 11pt, after=160 twips, line=259 (1.08x).

Page Layout
PropertyValue
Page size8.5" x 11" (12240 x 15840 twips)
Margins (all)1" (1440 twips)
Header/Footer distance0.5" (720 twips)
Gutter0
Section breakNext page
Document Parts (Glossary)

7 entries: TitlePageTitle, TitlePageSubtitle, TitlePageImage, TitlePageAuthor, TitlePagePublisher, TitlePagePubDate, TitlePage.

Each part (except TitlePage) wraps content in a styled paragraph with an inner Content hole. TitlePage is the composite with all 6 top-level holes + section properties.

PDF Template (.pdftx)
Holes (6)
Hole IDPlaceholderMaps to Property
TitleTITLEtp.Title
SubtitleSUBTITLEtp.Subtitle
ImageIMAGEtp.Image
AuthorAUTHORtp.Author
PublisherPUBLISHERtp.Publisher
PubDatePUBLICATION_DATEtp.PubDate
Styles (CSS)
ClassFont SizeBoldAlignmentMargin TopMargin Bottom
p.TitlePageTitle24ptYesCenter19pt10pt
p.TitlePageSubtitle20ptYesCenter16pt—
p.TitlePageImage——Center—10pt
p.TitlePageAuthor18ptYesCenter11pt—
p.TitlePagePublisher10ptNoCenter10pt—
p.TitlePagePubDate10ptNoCenter10pt—
Page Layout
PropertyValue
Page size8.5" x 11" portrait
Top/Bottom0.5" / 0.5"
Left/Right1" / 1"
Header/Footer0.5" / 0.5"
Gutter0

page-margin: 0.5in 1in 0.5in 1in 0.5in 0.5in 0in

Document Parts

Same 7 <dptemplate> entries as DOCX (in docpart_templates.html). Each wraps content in a styled <p> with a Content hole.

HTML Multi-file Template (.htmtx)

Byte-for-byte identical to PDF template. Same root.html, docpart_templates.html, root.css.

HTML Single-file Template (.htmt)

Same holes, styles, and document parts as PDF/HTML multi-file, with these differences:

AspectMulti-fileSingle-file
PackagingZip archiveSingle file
CSSExternal stylesheets/root.cssInline <style> in <head>
Document partsSeparate docpart_templates.htmlInline <dplibrary> in <body>
Top-level <layout>Present in root.htmlAbsent (only inside TitlePage dptemplate)
CSS wrappingPlain/*<![CDATA[*/.../*]]>*/

Chapter Reporter

Uses TemplateName = "Section" (shared with Section reporter).

Properties
PropertyDefaultPurpose
Title—Chapter title text
Numbered[] (auto)Whether to show autonumbers
Content—Child reporters/content
Layout—Page layout override
TemplateName"Section"Template name
DOCX Template (.dotx)
Holes

Section1 (used for Chapter/top-level):

Hole AliasPlaceholderPurpose
TitleTITLE1Chapter title
ContentCONTENTChapter body

SectionNumberedTitle parts (1-6):

Hole AliasPlaceholderPurpose
NumberPrefixNUMBER_PREFIXText before autonumber
NumberSuffixNUMBER_SUFFIXText after autonumber
ContentTITLE-CONTENTTitle text
Styles
Style IDFont SizeBoldItalicColorOutline LevelSpace BeforeKeep-Next
SectionTitle114pt (28 half-pts)Yes—#365F910480 twipsYes
SectionTitle213pt (26 half-pts)Yes—#4F81BD1200 twipsYes
SectionTitle311pt (inherit)Yes—#4F81BD2200 twipsYes
SectionTitle411pt (inherit)YesYes#4F81BD3200 twipsYes
SectionTitle511pt (inherit)——#243F604200 twipsYes
SectionTitle611pt (inherit)—Yes#243F605200 twipsYes
SectionTitleHeader12pt (24 half-pts)————360 twips—
SectionTitleFooter———————
SectionContent———————

All title styles: line=276 (1.15x), after=0.

Page Layout
PropertyValue
Page size8.5" x 11" (12240 x 15840 twips)
Margins (all)1" (1440 twips)
Header/Footer distance0.5" (720 twips)
Gutter0
First page differentYes (<w:titlePg/>)
Headers & Footers
FileContent
header1.xmlSectionTitleHeader paragraph + horizontal rule (6pt bottom border)
footer1.xmlEmpty SectionTitleFooter paragraph
footer2.xmlSectionTitleFooter with PAGE field (page number)
Autonumbering

SEQ fields: sect1-sect6, figure, table. SectionNumberedTitle1 resets all lower counters plus figure/table.

Document Parts
docPartHolesNotes
Section1-Section6Title, ContentSection1 includes sectPr for page layout
SectionTitle1-SectionTitle6ContentStyled paragraph
SectionNumberedTitle1-SectionNumberedTitle6NumberPrefix, NumberSuffix, ContentSEQ fields + styled paragraph
PDF Template (.pdftx)
Holes

Same structure: Section1-Section6 each have Title + Content holes.

Title holes specify default-style-name:

dptemplateTitle styleContent style
Section1SectionTitle1SectionContent
Section2SectionTitle2SectionContent
Section3-6SectionTitle3-6SectionContent
Styles (CSS)
SelectorFontSizeWeightStyleColorMargin-Top
h1.SectionTitle1Cambria + Noto14ptbold—rgb(54,95,145)24pt
h2.SectionTitle2Cambria + Noto13ptbold—rgb(79,129,189)10pt
h3.SectionTitle3Cambria + Noto11ptbold—rgb(79,129,189)10pt
h4.SectionTitle4Cambria + Noto11ptbolditalicrgb(79,129,189)10pt
h5.SectionTitle5Cambria + Noto11pt——rgb(36,63,96)10pt
h6.SectionTitle6Cambria + Noto11pt—italicrgb(36,63,96)10pt
p.SectionTitleHeader—11pt——black—
p.SectionTitleFooter—11pt——black—
p.SectionContent—11pt———10pt

All titles: margin-bottom: 0pt, white-space: pre, -fo-keep-with-next.within-page: always.

Page Layout
PropertyValue
Page size8.5" x 11" portrait
Top/Bottom0.5" / 0.5"
Left/Right1" / 1"
Header/Footer0.5" / 0.5"
Gutter0
Page numberingDecimal (format="1")
Headers & Footers (PDF)
TemplateContent
SectionFirstPageHeaderEmpty SectionTitleHeader + <hr/>
SectionFirstPageFooter<hr/> + page number
SectionDefaultPageHeader<StyleRef style-name="SectionTitle1"/> + <hr/>
SectionDefaultPageFooter<hr/> + page number
SectionEvenPageHeader<StyleRef style-name="SectionTitle1"/> + <hr/>
SectionEvenPageFooter<hr/> + page number
Autonumbering (PDF)

<autonumber stream-name="sectN"> with counter-increment/reset CSS:

  • SectionNumberedTitle1: counter-increment:sect1; counter-reset:sect2 sect3 sect4 sect5 sect6 figure table

  • SectionNumberedTitle2: counter-increment:sect2; counter-reset:sect3 sect4 sect5 sect6

  • (continues to level 6)

HTML Single-file Template (.htmt)
AspectPDF (.pdftx)Single-file (.htmt)
<layout>In Section1None (browser rendering)
Headers/footers6 templatesNone
SectionContent styleDefinedNot defined
SectionTitleHeader/FooterDefinedNot defined
Font fallbacksIncludes 'Noto Emoji'Excludes 'Noto Emoji'
Autonumber stream namessect1-sect6h1-h6
Counter CSSIn <h> style attributesspan.an_sectN:before rules
SectionNumberedTitle1 resetsfigure tablefigure table
HTML Multi-file Template (.htmtx)

Identical to PDF template in structure and content.


Cross-Format Summary

Format Packaging
FormatExtensionStructure
Word.dotxZip (OpenXML): word/document.xml, word/styles.xml, word/glossary/document.xml
PDF.pdftxZip: root.html, stylesheets/root.css, docpart_templates.html
HTML multi-file.htmtxZip: same as PDF
HTML single-file.htmtSingle file: inline CSS + inline dplibrary
Hole Mechanism
FormatHole syntaxInner holes
DOCX<w:sdt> with <w:tag w:val="Hole"/> and <w:alias>Same
PDF/HTML<hole id="Name">placeholder</hole>Same
Document Part Library
FormatLocationEntry syntax
DOCXword/glossary/document.xml<w:docPart><w:docPartPr><w:name w:val="..."/>
PDF/HTML multi-filedocpart_templates.html<dptemplate name="..."> inside <dplibrary>
HTML single-fileInline in bodySame <dptemplate> inside inline <dplibrary>
Page Layout Differences (TitlePage)
PropertyDOCXPDF/HTML
Top margin1"0.5"
Bottom margin1"0.5"
Left/Right1"1"
Naming Convention: PubDate Placeholder
FormatPlaceholder text
DOCXPUB_DATE
PDF/HTMLPUBLICATION_DATE

TableOfContents Reporter

Properties
PropertyDefaultPurpose
Title[] (empty)TOC heading text
NumberOfLevels3How many heading levels to include
TemplateName"TableOfContents"Template name
DOCX Template (.dotx)
Holes (2, in TableOfContents docpart)
Hole AliasPlaceholderPurpose
TitleTITLETOC heading (styled with TableOfContentsTitleChar)
TOCObjTOC_OBJECTThe generated table of contents
Styles
Style IDFontFont SizeBoldSpacing AfterLine Spacing
TableOfContentsTitleArial20pt (40 half-pts)Yes200 twips240 (single)

Base defaults: Calibri 11pt, after=160 twips, line=259 (1.08x).

Page Layout
PropertyValue
Page size8.5" x 11" (12240 x 15840 twips)
Margins (all)1" (1440 twips)
Header/Footer distance0.5" (720 twips)
Gutter0
Headers & Footers
FileContent
header1.xmlEmpty (Header style)
footer1.xmlCentered PAGE field (page number)

The glossary also defines header2.xml (empty with spaces) and footer2.xml (centered PAGE field) for use within the TableOfContents docpart's sectPr.

Document Parts (Glossary)
docPartContent
TableOfContentsTitleParagraph styled TableOfContentsTitle with inner Content hole
TableOfContentsComposite: Title hole + TOCObj hole + sectPr (page layout + header/footer refs)
PDF Template (.pdftx)
Holes

The root.html body contains:

ElementPurpose
<hole id="Title" default-style-name="TableOfContentsTitle">TOC heading
<toc/>Native TOC element (not a hole — generated automatically)

The TableOfContents dptemplate has:

Hole IDPlaceholderPurpose
TitleTITLETOC heading
TOCObjTOC_OBJECTGenerated TOC content
Styles (CSS)
SelectorFont SizeBoldColorMargin TopMargin BottomAlignment
h1.TableOfContentsTitle, p.TableOfContentsTitle16ptYesblack16pt10pt—
p.TableOfContentsTitleHeader10ptNoblack——Center
p.TableOfContentsTitleFooter10ptNoblack——Center

All styles: white-space: pre.

Page Layout
PropertyValue
Page size8.5" x 11" portrait
Top/Bottom0.5" / 0.5"
Left/Right1" / 1"
Header/Footer0.5" / 0.5"
Gutter0
Page numberingLowercase Roman (format="i")

page-margin: 0.5in 1in 0.5in 1in 0.5in 0.5in 0in

Headers & Footers (PDF)
TemplateContent
rgTableOfContentsFirstPageHeaderEmpty TableOfContentsTitleHeader
rgTableOfContentsFirstPageFooter<page/> (page number)
rgTableOfContentsDefaultPageHeaderEmpty TableOfContentsTitleHeader
rgTableOfContentsDefaultPageFooter<hr/> + <page/>
rgTableOfContentsEvenPageHeaderEmpty TableOfContentsTitleHeader
rgTableOfContentsEvenPageFooter<hr/> + <page/>
HTML Multi-file Template (.htmtx)

Significantly different from PDF — designed for interactive browser viewing.

Holes (2, in TableOfContents dptemplate)
Hole IDPlaceholderdefault-style-name
TitleTITLETableOfContentsTitle
TOCObjTOC_OBJECTTOC
Styles (CSS)
SelectorProperties
p.TableOfContentsTitle12pt, bold
TOC (element)background: #f2f2f2 (light gray), display: none (hidden by default)
ul.TOCItemsno bullets, padding-left: 1em
ul.TOCItems ulno bullets, padding-left: 1.2em
a.TOCItemTitleArial, 10pt, bold, blue, underlined
span.TOCHandle10x10px box, expand/collapse icon
Document Parts
dptemplateContent
TableOfContents<div> wrapping Title hole + TOCObj hole
TableOfContentsTitle<p class="TableOfContentsTitle"> with expand/collapse <span> handle + Content hole
Interactive Behavior

The HTML template includes a collapsible TOC: a clickable span.TOCHandle with onclick="util.toggleTOCVisibility(...)" toggles the TOC element between visible/hidden. Plus/minus icons indicate state.

No <layout>, no headers/footers, no page numbering (browser rendering).

HTML Single-file Template (.htmt)

Identical to multi-file HTML in structure and CSS. Same interactive expand/collapse behavior.

AspectMulti-file (.htmtx)Single-file (.htmt)
CSSExternal root.cssInline <style> with CDATA wrapping
dplibrarySeparate docpart_templates.htmlInline in <body>
Key Differences Across Formats
AspectDOCXPDFHTML
Title fontArial 20pt16pt (default font)12pt (default font)
Page numberingArabic (PAGE field)Lowercase Roman (i, ii, iii)N/A
TOC mechanismTOCObj hole (Word TOC field)<toc/> elementInteractive collapsible div
Headers/FootersEmpty header, page# footerEmpty header, hr+page# footerNone
Page margins1" all sides0.5" top/bottom, 1" sidesN/A

Report Reporter

The Report template is a container — it provides global page layout, base styles, and interactive infrastructure but has no holes. Content comes from child reporters (TitlePage, Chapter, TableOfContents, etc.) added via add().

Properties
PropertyDefaultPurpose
OutputPath—Output file path
Type"pdf"Output format: "pdf", "docx", "html", "html-file"
PackageType""Package type (single-file vs zipped)
TemplatePath—Path to custom template
Locale""Locale for report
Debug—Debug mode
Layout—Page layout override
DOCX Template (.dotx)
Holes

None. The document body is empty — just a blank paragraph with section properties.

No Glossary / No Document Parts

Unlike TitlePage, Chapter, and TableOfContents, the Report DOCX template has no word/glossary/ folder and no document parts.

Page Layout
PropertyValue
Page size8.5" x 11" (12240 x 15840 twips)
Margins (all)1" (1440 twips)
Header/Footer distance0.5" (720 twips)
Gutter0
Doc gridlinePitch=360
No Headers/Footers

No header or footer XML files — child reporters (Chapter, TOC) supply their own via their docpart sectPr definitions.

Styles (93 paragraph + 3 table)

The Report template provides the master style catalog used by all child reporters:

Heading styles (Heading1-Heading9):

StyleSizeBoldItalicColorSpace Before
Heading114pt (28 half-pts)Yes—#365F91480 twips
Heading213pt (26 half-pts)Yes—#4F81BD200 twips
Heading311pt (inherit)Yes—#4F81BD200 twips
Heading411pt (inherit)YesYes#4F81BD200 twips
Heading511pt (inherit)——#243F60200 twips
Heading611pt (inherit)—Yes#243F60200 twips
Heading711pt (inherit)—Yes#404040200 twips
Heading810pt (20 half-pts)——#404040200 twips
Heading910pt (20 half-pts)—Yes#404040200 twips

All headings: keepNext, keepLines, line=276 (1.15x), after=0, major theme font (Cambria).

TOC styles (TOC1-TOC9): For Word's built-in table of contents field.

List styles: ListBullet (1-5), ListNumber (1-5), ListContinue (1-5), ListParagraph, List (1-5).

Table styles:

StyleProperties
TableNormalDefault (cell margins: 108 twips left/right)
TableGridStandard grid
rgMATLABTableCentered text, Calibri font, bold first row, no spacing

Other notable styles: Title (56 half-pts/28pt), Subtitle (colored text), Caption, BlockText, BodyText variants, HTMLPreformatted (Consolas 10pt).

Numbering Definitions

23 abstract numbering definitions + 25 instances for all list styles (ListBullet, ListNumber, etc.).

PDF Template (.pdftx)
Holes

None. The body is empty (contains only a commented-out layout example).

No Document Parts

Empty <dplibrary>.

Page Layout

Commented out (not active by default):

<!-- <layout style="page-margin: 1in 1in 1in 1in 0.5in 0.5in 0in; page-size: 8.5in 11in portrait" /> -->

Child reporters provide their own <layout> elements.

Styles (CSS)

TOC styles:

SelectorSizeIndent
p.TOC110pt0
p.TOC210pt24pt
p.TOC310pt48pt
p.TOC410pt72pt
p.TOC510pt96pt
p.TOC610pt120pt
p.LOC10pt0

All TOC styles: margin-bottom 2pt.

Heading styles (h1-h6):

SelectorFontSizeWeightStyleColorMargin-Top
h1Cambria + Noto + Noto Emoji14ptbold—rgb(54,95,145)24pt
h2Cambria + Noto + Noto Emoji13ptbold—rgb(79,129,189)10pt
h3Cambria + Noto + Noto Emoji11ptbold—rgb(79,129,189)10pt
h4Cambria + Noto + Noto Emoji11ptbolditalicrgb(79,129,189)10pt
h5Cambria + Noto + Noto Emoji11pt——rgb(36,63,96)10pt
h6Cambria + Noto + Noto Emoji11pt—italicrgb(36,63,96)10pt

All headings: margin-bottom 0, white-space pre, -fo-keep-with-next.within-page: always.

Other styles:

SelectorPurpose
p.LinkTargetWrapperline-height: 0pt; keep-with-next (invisible anchor wrapper)
ablue, underlined
hr0.5pt solid black
table.rgMATLABTablecentered, no border, bold th, tight padding
table/th/td/trdefault border-width: 1px (all sides)
HTML Multi-file Template (.htmtx)
Holes

None. Empty body with onload="outline()".

No Document Parts

Empty <dplibrary>.

JavaScript Infrastructure

9 external script files:

ScriptPurpose
cssrule.jsCSS rule manipulation
toc.jsHTML outline algorithm for TOC generation
util.jsAutonumbering, TOC/LOF/LOT visibility toggles
moduletabs.jsTabbed content panes
loc.jsList of Contents (figures/tables)
sidebar.jsCollapsible sidebar navigation
sort-table.jsSortable table columns
collapsible.jsCollapsible table rows
chart.jsamCharts 4 integration

Also loads amCharts 4 from CDN (cdn.amcharts.com).

Styles (CSS)

Heading styles (h1-h6): Same as PDF but without 'Noto Emoji' in font fallback and without -fo-keep-with-next.

Body/table/list fonts: Noto Sans + CJK variants.

Table: rgMATLABTable (centered, bold th, tight padding).

Sidebar navigation CSS: Fixed position, 200px wide, animated slide-in, overlay backdrop, hamburger button.

Interactive styles: .collapsible cursor pointer, hover highlight.

Image Assets

4 PNG files for expand/collapse TOC handles: plus.png, plus-hover.png, minus.png, minus-hover.png.

HTML Single-file Template (.htmt)

Same as multi-file but all JS inlined in <script> blocks within <head>. Same empty dplibrary. Same interactive behavior.

Key Differences Across Formats
AspectDOCXPDFHTML
HolesNoneNoneNone
Document partsNoneNone (empty dplibrary)None (empty dplibrary)
Page layoutActive (1" margins)Commented outN/A (browser)
Heading fontMajor theme (Cambria)Cambria + Noto EmojiCambria + Noto Sans
TOC stylesBuilt-in Word TOC1-9p.TOC1-6 (indented)JS-generated outline
Table stylergMATLABTable (Word table style)rgMATLABTable (CSS)rgMATLABTable (CSS)
Numberingnumbering.xml (23 defs)N/A (handled by DOM)JS autonumber
InteractiveNoNoYes (sidebar, sortable, collapsible, tabs)
Architecture Note

The Report template is the root container. It:

  1. Defines the global style catalog (headings, tables, lists, TOC) that child reporters inherit

  2. Provides page layout defaults (though PDF leaves this commented out, letting child reporters define their own)

  3. In HTML, supplies all JavaScript infrastructure for interactive features

  4. Has no holes — child reporters are appended directly to the document body


BaseTable Reporter

Properties
PropertyDefaultPurpose
Title—Table caption/title
Content—Table data (array, table, DOM table)
TableStyleName""CSS/Word table style name
TableWidth—Table width
MaxCols—Max columns before slicing
RepeatCols—Columns repeated on each slice
TableSliceTitleStyleName—Style for slice continuation titles
TableEntryUpdateFcn—Callback for custom cell formatting
TemplateName"BaseTable"Template name
DOCX Template (.dotx)
Holes (2, in BaseTable docpart)
Hole AliasPlaceholderPurpose
TitleTITLETable caption
ContentCONTENTTable body
Styles
Style IDFontSizeBoldSpace BeforeSpace AfterLineKeep-NextWidow Control
BaseTableTitleTimes New Roman12pt (24 half-pts)Yes200 twips100 twips260 atLeastYesOff
BaseTableSlicedTableContentTitleTimes New Roman11pt (inherit)Yes200 twips100 twips260 atLeastYesOff

BaseTableSlicedTableContentTitle is used in the main document body (for sliced table continuation titles).

Page Layout
PropertyValue
Page size8.5" x 11" (12240 x 15840 twips)
Margins (all)1" (1440 twips)
Header/Footer distance0.5" (720 twips)
Gutter0
Headers/FootersEven, default, and first (all referenced)
Document Parts (Glossary)
docPartStyleHolesPurpose
BaseTableNormalTitle, ContentMain composite template
BaseTableContentNormalContentWraps the table content
BaseTableNumberedTitleBaseTableTitleNumberPrefix, NumberSuffix, ContentCaption with flat numbering: SEQ table
BaseTableHierNumberedTitleBaseTableTitleNumberPrefix, NumberSuffix, ContentCaption with hierarchical numbering: SEQ sect1 \c.SEQ table
Autonumbering (DOCX)
  • BaseTableNumberedTitle: SEQ table \* ARABIC — flat table counter

  • BaseTableHierNumberedTitle: SEQ sect1 \c \* ARABIC (current chapter, no increment) + . + SEQ table \* ARABIC — gives "1.1", "1.2", etc.

PDF Template (.pdftx)
Holes (2, in BaseTable dptemplate)
Hole IDPlaceholderPurpose
TitleTITLETable caption
ContentCONTENTTable body
Styles (CSS)
SelectorSizeBoldSpacingOther
p.BaseTableTitle12ptYespadding-top: 12pt, margin-bottom: 7.3ptblack, white-space: pre, keep-with-next
table.BaseTableContent td/th10pt—padding: 2pt allborder: solid 1px
p.BaseTableSlicedTableContentTitle10ptYespadding-top: 10pt, margin-bottom: 7.3ptblack, white-space: pre, keep-with-next
Document Parts
dptemplateHolesPurpose
BaseTableTitle, ContentMain composite
BaseTableContentContent (default-style-name="BaseTableContent")Table content wrapper
BaseTableNumberedTitleNumberPrefix, NumberSuffix, ContentFlat: <autonumber stream-name="table"/>
BaseTableHierNumberedTitleNumberPrefix, NumberSuffix, ContentHierarchical: <autonumber stream-name="sect1"/>.<autonumber stream-name="table"/>

Both numbered title templates use style="counter-increment:table" on the <p>.

No Page Layout

Empty <body> in root.html — inherits from parent (Report/Chapter).

HTML Multi-file Template (.htmtx)

Same document parts as PDF. Styles differ slightly:

SelectorSizeBoldSpacingOther
p.BaseTableTitle12ptYesmargin-top: 12pt, margin-bottom: 7.3ptblack, white-space: pre
table.BaseTableContent td/th16px——border: solid 1px, border-collapse, normal weight/style
table.BaseTableContent———border-collapse: collapse
p.BaseTableSlicedTableContentTitle10ptYesmargin-top: 10pt, margin-bottom: 7.3ptblack, white-space: pre

Autonumber CSS counters:

span.an_sect1:before {content: counter(sect1);}
span.an_table:before {content: counter(table);}
HTML Single-file Template (.htmt)

Identical to multi-file HTML in structure, styles, and document parts. CSS is inline.

Key Differences Across Formats
AspectDOCXPDFHTML
Title fontTimes New Roman 12pt12pt (default)12pt (default)
Title spacingbefore 200tw, after 100twpadding-top 12pt, margin-bottom 7.3ptmargin-top 12pt, margin-bottom 7.3pt
Table cellsStyled by table style (rgMATLABTable or custom)10pt, 1px border, 2pt padding16px, 1px border, border-collapse
NumberingSEQ fields (table, sect1\c)<autonumber> elementsCSS counter spans
Sliced title styleTimes New Roman 11pt bold10pt bold10pt bold
Localization

The BaseTableTitleNumberPrefixSuffix.xml file provides locale-aware prefix/suffix for table captions:

LocalePrefixSuffix
en"Table "". "
de"Tabelle "". "
fr"Tableau "". "
ja"表 "". "
zh"表 "". "

(30+ locales defined)


Figure Reporter

Properties
PropertyDefaultPurpose
Source—Figure handle or file path
Snapshot—Image object of the figure
SnapshotFormat"svg"Image format (svg, png, jpg, etc.)
Scaling—Image scaling mode
Height—Custom height
Width—Custom width
PreserveBackgroundColor—Keep figure background
Theme—Graphics theme for printing
TemplateName"Figure"Template name
DOCX Template (.dotx)
Holes (1, in Figure docpart)
Hole AliasPlaceholderPurpose
ContentCONTENTThe assembled figure (image + caption)

The Figure docpart is a simple wrapper with a single Content hole. The image and caption are filled via separate document parts.

Styles
Style IDFontSizeBoldSpace BeforeSpace AfterLineOther
FigureImage(inherit)(inherit)—200 twips0(inherit)Paragraph style for image placement
FigureCaptionArial10pt (20 half-pts)—120 twips200 twips240 (single)Caption text below image

Also defines rgTableTitle (Times New Roman 10pt, keepNext, before 200tw, after 100tw) — likely inherited from a shared base.

Page Layout
PropertyValue
Page size8.5" x 11" (12240 x 15840 twips)
Margins (all)1" (1440 twips)
Header/Footer distance0.5" (720 twips)
Gutter0

Main body contains a paragraph styled FigureImage (used as the image area).

Document Parts (Glossary)
docPartStyleHolesPurpose
FigureNormalContentMain composite — wraps everything
FigureImageFigureImageContent (placeholder: IMAGE_CONTENT)Image paragraph
FigureNumberedCaptionFigureCaptionNumberPrefix, NumberSuffix, ContentFlat: SEQ figure
FigureHierNumberedCaptionFigureCaptionNumberPrefix, NumberSuffix, ContentHierarchical: SEQ sect1 \c.SEQ figure
Autonumbering (DOCX)
  • FigureNumberedCaption: SEQ figure \* ARABIC — flat figure counter

  • FigureHierNumberedCaption: SEQ sect1 \c \* ARABIC (current chapter) + . + SEQ figure \* ARABIC — gives "1.1", "1.2", etc.

PDF Template (.pdftx)
Holes (1, in root.html body)
Hole IDPlaceholderPurpose
ContentCONTENTThe assembled figure
Styles (CSS)
SelectorSizeProperties
p.FigureCaption10ptblack, white-space: pre, -fo-keep-with-previous.within-page: always
p.FigureImage—margin-bottom: 10pt
Document Parts
dptemplateHolesPurpose
FigureContentMain composite
FigureImageContent (in <p class="FigureImage">)Image paragraph
FigureHierNumberedCaptionNumberPrefix, NumberSuffix, ContentHierarchical: <autonumber stream-name="sect1"/>.<autonumber stream-name="figure"/>
FigureNumberedCaptionNumberPrefix, NumberSuffix, ContentFlat: <autonumber stream-name="figure"/>

Both caption templates use style="counter-increment:figure" on the <p>.

No Page Layout

Empty <body> in root.html (only a Content hole) — inherits from parent.

HTML Multi-file Template (.htmtx)

Same structure as PDF template (separate docpart_templates.html + root.css). Same document parts.

HTML Single-file Template (.htmt)

Same document parts as PDF/multi-file HTML, with:

  • Inline CSS (same styles)

  • Autonumber via CSS counters: span.an_sect1:before, span.an_figure:before

Key Differences Across Formats
AspectDOCXPDFHTML
Caption fontArial 10pt10pt (default)10pt (default)
Caption positionBelow image (keep-with via next:Normal)Below image (keep-with-previous)Below image
Image spacingbefore 200tw, after 0margin-bottom 10ptmargin-bottom 10pt
Caption spacingbefore 120tw, after 200tw(none specified beyond font)(none specified)
NumberingSEQ fields (figure, sect1\c)<autonumber> elementsCSS counter spans
Comparison with BaseTable

The Figure reporter mirrors BaseTable's numbering pattern:

AspectFigureBaseTable
Counter namefiguretable
Flat templateFigureNumberedCaptionBaseTableNumberedTitle
Hier templateFigureHierNumberedCaptionBaseTableHierNumberedTitle
Caption styleFigureCaption (Arial 10pt)BaseTableTitle (Times New Roman 12pt bold)
Caption positionBelow imageAbove table
Keep-withkeep-with-previous (stays with image above)keep-with-next (stays with table below)
Localization fileNone (hardcoded in reporter)BaseTableTitleNumberPrefixSuffix.xml

FormalImage Reporter

Properties
PropertyDefaultPurpose
Image—Image path or DOM Image object
Caption—Caption text
Width—Image width
Height—Image height
Map—Image map (clickable regions)
ScaleToFit—Scale image to fit page
TemplateName"FormalImage"Template name
DOCX Template (.dotx)
Holes (2, in FormalImage docpart)
Hole AliasPlaceholderPurpose
ImageIMAGEThe image content
CaptionCAPTIONThe caption content
Styles
Style IDFontSizeSpace BeforeSpace AfterLine
FormalImageImage(inherit)(inherit)200 twips0240 (single)
FormalImageCaptionArial10pt (20 half-pts)120 twips200 twips240 (single)
Page Layout

Same as other reporters: 8.5" x 11", 1" margins, 720 twips header/footer.

Document Parts (Glossary)
docPartStyleHolesPurpose
FormalImageNormalImage, CaptionMain composite — two separate holes
FormalImageImageFormalImageImageContent (placeholder: IMAGE)Image paragraph
FormalImageNumberedCaptionFormalImageCaptionNumberPrefix, NumberSuffix, ContentFlat: SEQ figure
FormalImageHierNumberedCaptionFormalImageCaptionNumberPrefix, NumberSuffix, ContentHierarchical: SEQ sect1 \c.SEQ figure
Autonumbering (DOCX)

Same as Figure reporter:

  • FormalImageNumberedCaption: SEQ figure \* ARABIC

  • FormalImageHierNumberedCaption: SEQ sect1 \c \* ARABIC + . + SEQ figure \* ARABIC

PDF Template (.pdftx)
Holes (2, in FormalImage dptemplate)
Hole IDPlaceholderPurpose
ImageIMAGEImage content
CaptionCAPTIONCaption content
Styles (CSS)
SelectorSizeProperties
p.FormalImageImage—margin-bottom: 10pt
p.FormalImageCaption10ptblack, white-space: pre, -fo-keep-with-previous.within-page: always
Document Parts
dptemplateHolesPurpose
FormalImageImage, CaptionMain composite
FormalImageImageContent (in <p class="FormalImageImage">)Image paragraph
FormalImageHierNumberedCaptionNumberPrefix, NumberSuffix, ContentHierarchical: <autonumber stream-name="sect1"/>.<autonumber stream-name="figure"/>
FormalImageNumberedCaptionNumberPrefix, NumberSuffix, ContentFlat: <autonumber stream-name="figure"/>

Both caption templates use style="counter-increment:figure" on the <p>.

No Page Layout

Empty <body> in root.html — inherits from parent.

HTML Single-file Template (.htmt)

Same document parts as PDF. Inline CSS. Autonumber via:

span.an_sect1:before {content: counter(sect1);}
span.an_figure:before {content: counter(figure);}
HTML Multi-file Template (.htmtx)

Same as single-file but with external CSS and separate docpart_templates.html.

Key Differences from Figure Reporter
AspectFormalImageFigure
Main holesImage + Caption (separate)Content (single composite)
Style prefixFormalImage*Figure*
Image propertyImage (path or DOM object)Source (figure handle or path)
Snapshot supportNo (static images only)Yes (captures MATLAB figures)
LocalizationFormalImageCaptionNumberPrefixSuffix.xml (30+ locales)None
Use caseStatic images with captionsMATLAB figure snapshots

The FormalImage template has two top-level holes (Image + Caption) whereas Figure has just one (Content). This means FormalImage gives more template-level control over image/caption layout.

Localization
LocalePrefixSuffix
en"Figure "". "
de"Abbildung "". "
fr"Figure "". "
ja"図 "". "
zh"图 "". "

(30+ locales defined via TitleNumberPrefix / TitleNumberSuffix)


Copyright 2026 The MathWorks, Inc.


Requirements and compatibility

Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta

“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.

Needs: Needs an MCP server

Security

No issues found by our static scan· No issues found

A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.

Attribution and licence

Created by
MathWorks
Publisher
MathWorks (Official)
Source
matlab/matlab-agentic-toolkit · skills-catalog/reporting-and-database-access/matlab-generate-report · commit 2a7f215
Licence
BSD 2-Clause License (redistribution allowed)
  • LICENSE (added by AutoGineer from LICENSE.md)
  • ATTRIBUTION.md (written by AutoGineer)
Synced

AutoGineer is not affiliated with or endorsed by MathWorks or MathWorks.

Download ZIP

The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download matlab-generate-report.zip