%%{init: {"themeVariables": {"fontSize": "22px"}}}%%
flowchart TB
A[Field records] --> B[(Database)]
B --> C[Data connection]
C --> D[Checks and estimates]
D --> E[Quarto template]
E --> F[Published report]
S[Scheduler] -.-> C
Building a Creel Report That Updates During the Season
A practical setup with a database, tidycreel, and Quarto

Suppose a creel program wants an updated report every week of the season. The field team already records counts and angler interviews in a database. The analyst already knows how to estimate effort and catch. How do we connect those pieces so the same report can run again as new data arrive?
I would build a small reporting pipeline: read the database, prepare and check the survey data, calculate estimates with tidycreel, and let Quarto assemble the results into a report. A scheduler starts the pipeline at a regular time. Here is what that setup looks like, from the data source to the published page.
The whole system
This diagram has two paths. The solid arrows show how information moves. The dotted arrow shows what starts each run. The scheduler does not calculate a creel estimate; it tells the same prepared analysis to run again.
I would organize the work around five setup decisions.
1. Decide what the report needs
Before connecting software, write down the questions the report will answer and the period each answer covers. For example: season-to-date fishing effort, catch rates, and estimated catch or harvest, where the survey design supports them. Choose the tables and figures biologists and managers need, along with the units, uncertainty, and a short explanation of what each estimate means.
This list determines which database records the job must retrieve. Counts, interviews, catch details, a sampling calendar, and design information may all be needed. It also sets the boundary for the first version: one useful report is easier to establish than every possible breakdown at once.
A possible report outline
A detailed creel report can separate survey design, direct summaries of interviews, estimated effort and catch, and technical appendices. For a routine in-season version, I would keep that distinction but put the most useful results first:
- Report at a glance. Name the waterbody, reporting period, database cutoff, and report run time. Give a few key findings in plain language.
- Survey coverage. Show planned and completed count visits, the number of interviews, and coverage by month, day type, and angler type. Explain any important gaps before showing estimates.
- Fishing effort. Present estimated angler hours and, if supported, angler trips by month and by bank or boat anglers. Include uncertainty with each estimate.
- Catch, release, and harvest. Show estimated rates and totals by species, with monthly detail where the sample supports it. Define the units and distinguish fish caught from fish kept or released.
- What the interviews describe. Summarize species sought, fishing methods, trip lengths, participation, and any supplemental questions that matter to managers. Label these as summaries of interviewed parties, rather than fishery-wide estimates.
- Interpretation and supporting detail. Explain what changed, what remains uncertain, and which comparisons the design supports. Put the full tables, species codes, survey design, and calculation notes in an appendix.
This gives biologists and managers a short path through the report while preserving the detailed material analysts need. The same outline can be rendered every week; sections with insufficient data can say so instead of producing a misleading number.
2. Prepare a dependable database handoff
Why centralize the creel records?
A centralized database gives field staff, reviewers, and analysts a shared record of the season. Counts, interviews, and linked catch details can use the same identifiers and definitions. Staff can correct a record in one place, and the next report run can pick up that correction. The database can also retain who entered or reviewed a record and when, which makes a surprising result easier to trace back to its source.
That shared source makes routine reporting much simpler. The scheduled job can request the same reporting tables each time, whether it produces a weekly summary, a month-end report, or a later interactive display. This reduces the work of reconciling separate spreadsheet copies for every edition. These benefits depend on agreed data definitions, careful entry and review, and a reliable way to identify the records included in each run.
The report should read from a defined set of database tables or views. A view is a saved way of presenting selected database records; the database team can use it to provide records that are ready for reporting. The report job should have read-only access. It should read related tables from one database snapshot or cutoff, so an interview and its catch details cannot come from different moments in an update.
In the data connection post, I introduced tidycreel.connect. Its connection profile maps the program’s table and column names to the names tidycreel expects. The database team and analyst would agree on that mapping and on the rule for which records the views expose. tidycreel.connect retrieves records; it does not decide whether a field record is approved.
A small part of the report code might look like this:
# The profile points to the program's reporting tables or views.
conn <- tidycreel.connect::creel_connect_from_yaml("creel-config.yml")
counts <- tidycreel.connect::fetch_counts(conn)
interviews <- tidycreel.connect::fetch_interviews(conn)A real report would also retrieve any linked catch and measurement records it uses. Its database credentials belong in the job’s environment, not in the report file.
3. Put the analysis in one repeatable sequence
After the records arrive, the job checks them before estimating anything. Did the expected visits appear? Are identifiers unique? Do catch records match their interviews? Are dates and values plausible? The diagnostics post explains why a recorded zero, a missing value, and an unsampled day need different treatment.
The analyst then supplies the survey calendar and design, sets the reporting period, and runs the tidycreel estimation steps. A season-to-date report should estimate the period that has actually elapsed; future dates in a planning calendar are not observations. If a required check fails, the job should stop before replacing the published report and alert the report owner.
This sequence belongs in saved code that both a person and the scheduler can run. That way, a weekly report uses the same checks and calculations as the previous one. Method changes can be reviewed in that code before the next run.
4. Build the report template in Quarto
A Quarto file (.qmd) combines ordinary text with code, tables, and figures. I would give it a fixed structure: a reporting period and data summary at the top, sampling coverage next, then the estimates and their interpretation. The file calls the analysis sequence, places its outputs in the right sections, and renders an HTML report.
For a small first version, the project might contain:
creel-config.yml database table and column mapping
R/report-data.R data checks and estimation steps
reports/season.qmd report text, figures, and tables
These are illustrative names, not files supplied by tidycreel. The Quarto file can load R/report-data.R during its run.
There is already a Creel Report starter template in tidycreel. It includes survey design, data validation, interview summaries, and effort and catch estimates. To use it for this system, I would replace its example-data imports with the database handoff, set the season-to-date cutoff, and add the run information and concise opening summary described above. The template is a starting point that each program can adapt to its database and survey.
A person or scheduled job can produce the report with:
quarto render reports/season.qmd --to htmlThe report should name its reporting period, units, and uncertainty beside the results. It should also record when it was built and which data cutoff it used. That information helps someone interpret a saved copy later.
5. Schedule, check, and publish each run
Once the manual version works, set a schedule that matches how often staff enter and review data. A job on an agency computer may be the simplest choice if the database is on an internal network. GitHub Actions is another possibility when the network and credential policies permit it. Either way, the scheduled job runs the Quarto command, checks that it finished successfully, and then publishes the new HTML. If it fails, the last successful report remains available with its original date.
How current is it? The report uses records entered and approved in the database by its cutoff. Fieldwork still on paper or under review appears in a later run. Show both the report run time and the data period it includes.
I would test this pipeline against a few manually produced reports before relying on its schedule. That comparison can reveal differences in data selection, survey periods, or calculations while they are still easy to trace. Keep the report source, connection profile, and package versions together so a particular edition can be reproduced.
A Shiny app could later use the same checked data and estimation code to let biologists and managers explore results interactively. The scheduled report is the first useful system: a defined data handoff, one analysis path, one report template, and a routine way to run and publish it.