-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue #494: New workflow for creating and validating forecast objects #531
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #531 +/- ##
===========================================
+ Coverage 82.44% 82.47% +0.03%
===========================================
Files 20 20
Lines 1675 1678 +3
===========================================
+ Hits 1381 1384 +3
Misses 294 294 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This all looks good to me. Confused about the use of scoringutils_binary
etc. and I think could do with a bit more checking the as_forecast workflow makes sense and is used clearly.
Can you resolve and request another review when ready please! |
I updated We'll likely need another round of edits for the Vignette. I suggest to not mix that with this PR. I haven't finished updating the scoringutils manuscript yet and I think we can re-use parts of that, creating a coherent structure that makes sense. I opened #532 to keep track of this. Side note: I also made a new comment to #435 since I noticed that the current default for PR is good for another round of review. Thanks a lot! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice. All makes sense. Looks good to me.
Description
This PR closes #494.
This PR
validate.default()
with a new class construction helperas_forecast()
, a function that determines the forecast type, constructs a new class object, and validates that object.as_forecast()
is a generic with a single methodas_forecast.default()
that does the workvalidate()
(in the sense of the previousvalidate.default()
) in the code, the news file, and the testsscore()
andas_forecast()
a bit, such that a section that is common to both can be reusedvalidate()
tovalidate_forecast()
. The class construction helper (which was previouslyvalidate.default()
is therefore nowas_forecast()
and the validation function (previously the methods ofvalidate()
) are now methods ofvalidate_forecast()
Checklist
lintr::lint_package()
to check for style issues introduced by my changes.