Gilead-BioStats / gsm

Good Statistical Monitoring R Package
https://gilead-biostats.github.io/gsm/
Apache License 2.0
39 stars 9 forks source link

Fix summary tables in reports and add `metricTable` to `Visualize_Metric()` output #1769

Closed lauramaxwell closed 3 months ago

lauramaxwell commented 3 months ago

Overview

Resolves the bug in #1765 that tables were not rendering in report output.

Also adds the output of Report_MetricTable() to the MakeCharts()/Visualize_Metric() output as metricTable for easier reference in report generation.

Updated relevant documentation to note the addition of metricTable to lCharts list.

closes #1765

Test Notes/Sample Code

# Run reports
lCharts <- MakeCharts(
  dfResults = reportingResults,
  dfGroups = reportingGroups,
  dfMetrics = reportingMetrics,
  dfBounds = reportingBounds
)

## check to see that `metricTable` is in lCharts output
lCharts$kri0001$metricTable

strOutpath <- "StandardSiteReport.html"
Report_KRI(
  lCharts = lCharts,
  dfResults = reportingResults,
  dfGroups = reportingGroups,
  dfMetrics = reportingMetrics,
  strOutpath = strOutpath
)

Notes: