IMAP-Lo systematic error calculation fixes#3315
Conversation
|
Please wait on merging this PR till @frahmanif has had a chance to sign off on this ... |
|
Also tagging @mitchellshen and @hi1011 |
|
As we discussed, background rates and associated uncertainty (systematic uncertainty) are read from the hydrogen-background ancillary file. GF values are not involved in the rates calculations and thus the asymmetry in the systematic uncertainty error bars do not affect the bg rates uncertainties. In the next step, when we calculate bg flux and systematic uncertainty, the GF values and uncertainties are then used and we expect the asymmetry to be considered. |
The algorithm document (Appendix A, eq 64) specifies the background rate systematic as the exposure time weighted average of the per-pset systematic error. The systematic is a single symmetric value, so _plus and _minus are set equal to it for now. Note that the systematic errors are all 0s, since no constant has been introduced yet to populate this (to be Imap-Lo team supplied) value.
|
@frahmanif, @mitchellshen, @hi1011 - As per Fatemeh's input as well as what I could understand from the algorithm document, I've tweaked the calculation of The delta term = So the terms we're using in the code do have the "stat" or "sys" prefix, but call it the "statistical uncertainty" and "systematic error" respectively, while the document calls the latter "systematic uncertainty". This is a carryover from when the code was written and attributes in the CDF created, so hopefully it is not a big deal. So the In fact an existing test even asserts this: But that's a separate issue and we can tackle it in another PR. This PR is now done. |
tmplummer
left a comment
There was a problem hiding this comment.
This all looks fine to me.
0a6de2d
into
IMAP-Science-Operations-Center:dev
Closes #3314
Overview
[eV]).calculate_intensitiesandcalculate_backgroundsnow propagate the asymmetric GF uncertainty with the exact reciprocal relation (J·G/(G ∓ dG), emit _sys_err_plus / _sys_err_minus bounds, and store the geometric mean sqrt(minus·plus) in the existing_sys_errvariable. Applied toena_intensity,bg_rate, andbg_intensity.EDIT: Removed the GF correction for
bg_rate_sys_errsince it is independent of GF, as per the second commit (and comment below).