Ticket #9030 (closed: fixed)
Use the covariance matrix for fitting error propagation
Reported by: | Roman Tolchenov | Owned by: | Roman Tolchenov |
---|---|---|---|
Priority: | major | Milestone: | Release 3.2 |
Component: | Framework | Keywords: | |
Cc: | gesner.passos@… | Blocked By: | |
Blocking: | #8977 | Tester: | Wenduo Zhou |
Description (last modified by Roman Tolchenov) (diff)
At the moment to estimate the errors of the calculated values we are using the formula:
err = sqrt( sigma2 * J * JT )
where sigma are standard deviations of the parameters and J is the Jacobian. This doesn't take into account correlation between the parameters and may lead to overestimated errors. I want to try to use a more accurate formula:
err = sqrt( J * C * JT )
where C is the covariance matrix.
Attachments
Change History
comment:6 Changed 7 years ago by Roman Tolchenov
- Status changed from assigned to inprogress
Re #9030. Removed unused classes.
Changeset: 65a9f64fe4620062059b0f83f9f30e7a3fb586fc
comment:7 Changed 7 years ago by Roman Tolchenov
Re #9030. Use covariance matrix to estimate errors of calc. values
Changeset: 390e8021a205792408b1f86517aa1df87aee4270
comment:8 Changed 7 years ago by Roman Tolchenov
Re #9030. Added a unit test
Changeset: 18b7c64594ced719140c932ff96103f198f96f6d
comment:9 Changed 7 years ago by Roman Tolchenov
Re #9030. Changed getCovarianceMatrix to return a const Matrix
Changeset: a09765134950053c58031b555cae637822450238
comment:10 Changed 7 years ago by Roman Tolchenov
Re #9030. Use chi squared in error calculation
Changeset: db9ab977afc71f1788826529a0943b73fe432cd7
comment:11 Changed 7 years ago by Gesner Passos
- Blocking 9011 added
(In #9011) The entire fit will change the way it calculates error. It will have impact on CalculateTransmission.
comment:12 Changed 7 years ago by Roman Tolchenov
Re #9030. Removed unused classes.
Changeset: f4e931b6b86783b92b2008dcead357a8465cca4e
comment:13 Changed 7 years ago by Roman Tolchenov
Re #9030. Use covariance matrix to estimate errors of calc. values
Changeset: ed25aa030a67b2ca375cc4dcfd12f96bcd979fce
comment:14 Changed 7 years ago by Gesner Passos
re #9030: New reference results after changing fit error calculation
Changeset: 2e8562e590c618e48cec80657cae71a139a51b23
systemtest: https://github.com/mantidproject/systemtests/commit/2e8562e590c618e48cec80657cae71a139a51b23
comment:15 Changed 7 years ago by Gesner Passos
The last was not merged to develop, it is just a branch created in case Roman will need to merge them to develop later. The compare_errors.py was the file I used to compare the current results of SystemTests and the new ones when applying this ticket. Testers may be interested in using something like.
Changed 7 years ago by Gesner Passos
- Attachment compare_errors.py added
File that highlight the systemtests that will change with the new error propagation
comment:18 Changed 6 years ago by Roman Tolchenov
Merge branch 'master' into feature/9030_fitting_error_propagation
Conflicts:
Code/Mantid/Framework/API/inc/MantidAPI/IDomainCreator.h Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/FitMW.h Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/MultiDomainCreator.h Code/Mantid/Framework/CurveFitting/src/FitMW.cpp Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/FitMD.h Code/Mantid/Framework/MDEvents/src/FitMD.cpp
Re #9030
Changeset: 939b68caa756a22acd24c5a783d0dad9af34a6c5
comment:19 Changed 6 years ago by Roman Tolchenov
Re #9030. Fixed an error after a merge with master.
Changeset: df6aaf38132040ec98e993c059fb66c40aa98bde
comment:20 Changed 6 years ago by Roman Tolchenov
Re #9030. Fix a doxygen warning
Changeset: 34c1e2e3e6891da4ae1e75b72128ee30101cadc8
comment:21 Changed 6 years ago by Roman Tolchenov
Re #9030. Replaced files to avoid merge conflicts.
Changeset: 5d448583305f341145c55f8f6ebacb2dc5784238
comment:22 Changed 6 years ago by Roman Tolchenov
Re #9030. Updated ref files due to change in fitting errors.
Changeset: fa399288d2fa4758e84b4b2337bd65b2b4741aff
comment:23 Changed 6 years ago by Roman Tolchenov
- Status changed from inprogress to verify
- Resolution set to fixed
To test:
- Load MUSR00015189 from AutoTestData.
- Fit its 1st spectrum with a Polynomial(n=5) on interval 0.3-30.
- Plot the calculated spectrum with error bars.
- The error bars should be reasonable.
comment:24 Changed 6 years ago by Wenduo Zhou
- Status changed from verify to verifying
- Tester set to Wenduo Zhou
comment:25 Changed 6 years ago by Samuel Jackson
- Status changed from verifying to closed
Merge remote-tracking branch 'origin/feature/9030_fitting_error_propagation'
Full changeset: 74c7ae4bcdaf3aae0402e19e604f141b68c7129b
comment:26 Changed 6 years ago by Samuel Jackson
Merge remote-tracking branch 'origin/feature/9030_fitting_error_propagation'
Full changeset: 38c7de6d6b91630fbc36d06052a87fd20d5f87b6
comment:27 Changed 5 years ago by Stuart Campbell
This ticket has been transferred to github issue 9873
Could you add a bit more description please.