Skip to content

Conversation

@sbidari
Copy link
Collaborator

@sbidari sbidari commented Aug 26, 2025

closes #4 and #5

sbidari and others added 8 commits August 25, 2025 16:22
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…iven-dataset-type-and-disease' of https://github.com/CDCgov/hubhelpr into 4-create-a-hub-formatted-quantiles-baseline-forecasts-given-dataset-type-and-disease
@codecov-commenter
Copy link

codecov-commenter commented Aug 26, 2025

Codecov Report

❌ Patch coverage is 0% with 270 lines in your changes missing coverage. Please review.
✅ Project coverage is 17.73%. Comparing base (995e858) to head (e432180).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
R/generate_hub_baselines.R 0.00% 171 Missing ⚠️
R/generate_hub_ensemble.R 0.00% 98 Missing ⚠️
R/update_hub_target_data.R 0.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##             main      #11       +/-   ##
===========================================
- Coverage   81.33%   17.73%   -63.61%     
===========================================
  Files           1        3        +2     
  Lines          75      344      +269     
===========================================
  Hits           61       61               
- Misses         14      283      +269     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@sbidari sbidari requested a review from Copilot August 26, 2025 17:44
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds functionality to generate hub baseline and ensemble forecasts for disease monitoring. The changes introduce two main functions for creating forecasts: baseline models using CDC forecasting methods and ensemble models that aggregate multiple submissions.

Key changes:

  • Added baseline forecast generation using CDC baseline forecasting methods
  • Added ensemble forecast generation that aggregates multiple model submissions
  • Updated dependencies to include forecasting and hub-related packages

Reviewed Changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
R/generate_hub_baselines.R New module implementing baseline forecast generation with data latency checks
R/generate_hub_ensemble.R New module implementing ensemble forecast creation and aggregation
R/update_hub_target_data.R Updated to use forecasttools::write_tabular_file instead of readr::write_csv
DESCRIPTION Added new dependencies for forecasting packages and removed readr
NAMESPACE Exported the two new main functions
man/*.Rd Generated documentation files for the new functions

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@sbidari sbidari requested a review from dylanhmorris August 26, 2025 18:25
@sbidari
Copy link
Collaborator Author

sbidari commented Aug 26, 2025

Created #12 for adding tests

@sbidari sbidari requested a review from dylanhmorris August 26, 2025 22:15
Copy link
Contributor

@dylanhmorris dylanhmorris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like some of my earlier suggestions weren't applied. Did you mean to reject them @sbidari? Or has my GH just not updated?

@sbidari
Copy link
Collaborator Author

sbidari commented Aug 27, 2025

Looks like some of my earlier suggestions weren't applied. Did you mean to reject them @sbidari? Or has my GH just not updated?

I think they posted late. I am just seeing them now

@sbidari sbidari requested a review from dylanhmorris August 27, 2025 18:22
Comment on lines 86 to 88
if (!disease %in% c("covid", "rsv")) {
stop("'disease' must be either 'covid' or 'rsv'")
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Redo via checkmate as in the baseline function?

Copy link
Contributor

@dylanhmorris dylanhmorris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

  • A few more minor suggestions for consistency
  • Not for this PR, but using the ext = argument to fs::path means that in a future PR we could make the save file format configurable to anything write_tabular supports (i.e. (csv, tsv, parquet))

sbidari and others added 2 commits August 27, 2025 16:20
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@sbidari sbidari merged commit 986336e into main Aug 27, 2025
6 checks passed
@sbidari sbidari deleted the 5-create-a-hub-ensemble-forecasts-given-dataset-type-and-disease branch September 29, 2025 16:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

create a hub ensemble forecasts given dataset type and disease create a hub formatted quantiles baseline forecasts given dataset type and disease

4 participants