I’m trying to set limits on the number of signal events nSig in a single bin. When I define nSig[0,-10,100] I get a “reasonable” answer, and when I define nSig[0,0,100] I get another answer which looks incorrect. The behavior also depends on how HypoTestInverter::UseCLs() is set.
My impression is that the range of nSig should not matter. If anyone can help to understand why this difference shows up and what causes it, it would be appreciated.
Thanks! There are no error messages or complaints from Minuit. One difference I find is in the nSig[0,0,100] case during GetHypoTest there is an additional printout (which I don’t see with nSig[0,-10,100]):
INFO:Eval -- Using one-sided discovery qmu - setting qmu to zero muHat = 1.25489e-08 muTest = 58.5859
This is odd because in both cases I set ac.SetOneSided(True). Is there some reason that setting nSig[0,-10,100] might force a two sided limit? For the record setting ac.SetOneSided(False) doesn’t fix the problem.
@EtienneDreyer was looking at this and made a plot of the CLs values for the two nSig lower values. Maybe this helps shed some light on what is going on? Thanks for the help!
I think you are using for your null model (S+B) model a snapshot value of nSig=0. This might confuse the AsymptoticCalculator.
Use a non-zero initial value for nSig and it should be fine, like nSig[1, -10, 100] or nSig[1,0,100]
Thanks! Changing the initial value resolved the issue. I don’t quite understand the details of why the initial value of nSig matters since I expect the values to be determined by SetFixedScan(), however I am very happy that changing this seems to have resolved the discrepancy. Thanks very much!