Add/Modify ModelResult to Dataset class, for Model fitting and preparing for Multi-Dataset fittin#1015
Add/Modify ModelResult to Dataset class, for Model fitting and preparing for Multi-Dataset fittin#1015
Conversation
…t an alias for Dataset and preserving back-compatibility
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1015 +/- ##
=======================================
Coverage 92.92% 92.93%
=======================================
Files 10 10
Lines 3871 3876 +5
=======================================
+ Hits 3597 3602 +5
Misses 274 274 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
For thinking about workflows and example code, I feel that the next step could be to consider how one is supposed to construct Currently, If the idea would be that It's possible that some of the issues I think about are not meant to be solved by |
Description
This is the start of an effort to support multiple-dataset fitting. As outlined, discussed a bit at #1012, the basic idea is to make a
Datasetclass that hasdata,model, andparams, and the appropriate independent variables and can do a fit.As pointed out in #1012, this is essentially what
ModelResultis, so the first part of the PR here simply:a) renames
ModelResulttoDataset, but retains an alias and functions such assave_modelresult()(now an alias forsave_dataset()).b) adds a
labelattribute, defaulting toNone.This is not ready for merging, but to be part of the discussion at #1012.
Still needed:
a) use
labelas a prefix-prefix for all model component prefixes.b) add a
MultiDatasetclass (maybe sublcassing fromDataset, but probably needing several over-written methods) that contains a dictionary ofDatasets(keyed bylabel), and can do the prefix-management to organize theParametersandDatasets.At this point, all tests pass. I did fix one test for
load_modelresultthat tests an exception message, which now has better grammar. So far, I think we can say "nothing is broken by this" ;).Type of Changes
Tested on
Verification
Have you