This function performs a multi‑stage cleaning, filtering, and summarization of sound manifest data. It removes anomalous recordings, filters based on duration and start‑time frequency, writes the cleaned manifest to an Excel file, and generates summary tables and visual summaries for each recording group.
MakeSummaryTables(manifest_file, output_dir, workpath_root)A data frame containing the initial sound manifest created by CreateManifest(), including
at least the columns fileLength.min, startTime.hhmm,
group, plot, date.mmdd, area, and year.
Path to the Excel file to be written (cleaned manifest).
Directory where summary PNGs and the combined PDF will be written.
Invisibly returns a list with components:
df1 Filtered dataset after removing long recordings.
df2 Dataset filtered by deviation from mean duration.
df3 Dataset filtered by start‑time frequency.
summary_table Wide summary table of counts by
group/plot/date.
The processing steps are:
Remove rows where fileLength.min > 70.
Remove rows whose fileLength.min deviates by more than
5% from the mean duration.
Remove rows whose startTime.hhmm occurs in fewer than 5%
of the rows in the reference dataset.
Write the cleaned manifest (df3) to an Excel file.
Create a wide summary table of counts per group/plot/date.
Generate PNG summary tables for each group and combine them into a single PDF.
Progress bars and step messages are printed using the cli package.
if (FALSE) { # \dontrun{
MakeSummaryTables(manifest_file = sound_manifest,
output_dir = "cleaned_manifest.xlsx",
workpath_root = "output/")
} # }