Renders an automated HTML or PDF report from a completed event study task. Uses a bundled RMarkdown template with configurable sections.
Usage
generate_report(
task,
output_file = "event_study_report.html",
format = c("html", "pdf"),
title = "Event Study Report",
author = NULL,
sections = c("summary", "data", "diagnostics", "single_event", "multi_event",
"cross_sectional", "appendix"),
cross_sectional = NULL,
confidence_level = 0.95,
interactive = TRUE,
advice = NULL,
...
)Arguments
- task
A fitted
EventStudyTaskorPanelEventStudyTask.- output_file
Output file path. Default
"event_study_report.html".- format
Output format:
"html"(default) or"pdf".- title
Report title.
Author name (optional).
- sections
Character vector of sections to include. Any subset of:
"summary","data","diagnostics","single_event","multi_event","cross_sectional","appendix".- cross_sectional
Optional cross-sectional regression results to include.
- confidence_level
Confidence level for plots. Default 0.95.
- interactive
Logical. Use interactive plotly plots in HTML output. Default TRUE.
- advice
An optional grounded
Adviceobject returned byes_advise(task_type = "report_writing"). When supplied and a validAdvice, renders a new AI Advisor Interpretation section in the report. WhenNULL(the default), the existing render path is completely unchanged (byte-identical output). A supplied but invalidadvice(not anAdviceobject) is silently coerced toNULLwith exactly onewarning()— the report is never broken.- ...
Additional arguments passed to
rmarkdown::render.