Dear rooters (and especially Wouter)!
I’m still trying to understand the source of problems mentioned in my previous message:
http://root.cern.ch/phpBB3//viewtopic.php?f=15&t=9318
Unfortunately I cant provide minimal example of my program which gives bad fit when I exclude some interval from chi-2:
t.setRange("R1",lo_ch,excl_lo_ch);
t.setRange("R2",excl_up_ch,up_ch);
RooChi2Var chi2("chi2","chi2",dec_bkg,data,Range("R1,R2"),NumCPU(2));
Now I simplify my test-case.
- When I run attached program with minimization of chi2 at full range (no rejected points, Range(“full”)) i get some results:
full range
FCN=336.926 FROM HESSE STATUS=OK 23 CALLS 284 TOTAL
EDM=2.40462e-07 STRATEGY= 1 ERROR MATRIX ACCURATE
EXT PARAMETER INTERNAL INTERNAL
NO. NAME VALUE ERROR STEP SIZE VALUE
1 bg 3.19504e-02 1.69618e-03 1.28007e-05 -1.21137e+00
2 c_1 5.90994e+00 5.24812e-02 3.60408e-06 -1.12163e+00
3 t_shift 1.09368e+02 5.73925e-02 2.20431e-06 -9.48683e-01
4 tau 1.28628e+01 9.85724e-02 2.71604e-06 -8.37159e-01
- When I make 2 intervals that cover full range, i get output that differs from case (1)
t.setRange(“sig1”,100,130) ;
t.setRange(“sig2”,130,200) ;
2 ranges eq to full range
FCN=336.926 FROM HESSE STATUS=OK 23 CALLS 286 TOTAL
EDM=3.77207e-09 STRATEGY= 1 ERROR MATRIX ACCURATE
EXT PARAMETER INTERNAL INTERNAL
NO. NAME VALUE ERROR STEP SIZE VALUE
1 bg 4.38035e-02 2.33203e-03 1.48954e-05 -1.14909e+00
2 c_1 5.90993e+00 5.24812e-02 3.59880e-06 -1.12163e+00
3 t_shift 1.09368e+02 5.73925e-02 2.20167e-06 -9.48684e-01
4 tau 1.28628e+01 9.85727e-02 2.67833e-06 -8.37159e-01
Note: numbers are changing when i set “150” instead of “130” as middle point.
- When i exclude 2 points from full interval, all numbers are similar to (2)
t.setRange(“sig1”,100,128) ;
t.setRange(“sig2”,130,200) ;
2 ranges eq to full range - 2 points -- same as above
FCN=336.926 FROM HESSE STATUS=OK 23 CALLS 286 TOTAL
EDM=3.77207e-09 STRATEGY= 1 ERROR MATRIX ACCURATE
EXT PARAMETER INTERNAL INTERNAL
NO. NAME VALUE ERROR STEP SIZE VALUE
1 bg 4.38035e-02 2.33203e-03 1.48954e-05 -1.14909e+00
2 c_1 5.90993e+00 5.24812e-02 3.59880e-06 -1.12163e+00
3 t_shift 1.09368e+02 5.73925e-02 2.20167e-06 -9.48684e-01
4 tau 1.28628e+01 9.85727e-02 2.67833e-06 -8.37159e-01
Is it possible to understand, why the results of (1) and (2) are different though fitting occurs on the same range? And why the results of (2) are dependent on point that breaks full interval? I would rather expect difference between (2) and (3), but not btw. (1) and (2).
Does RooFit use some another technique in (2) and (3) than in (1)?
What are other possibilities to exclude points either from RooChi2Var or from data histogram (RooDataHist), or to make their contribution to chi2 eq. to 0?
I stress that in this example difference is negligibly small, but in my “big” program it’s much bigger.
Nevertheless I can notice similar behavior – introducing Range() in chi2 affects the rate of background component (see “bg” in (1) and (2)).
I’m greatly confused about this and would appreciate any help. Thanks.
testdecay.c (2.14 KB)