*** minuicon.kumac *** *** This PAW macro demonstrates the generation of MINUIT contours in PAW; *** a 3-parameter gaussian fit to a 1-dim. histogram is used as an example. *** *** L. Ramello, A. Stamerra, S. Valchierotti (1999) *** opt pto opt nbox opt tic opt fit set fit 111 set ygti 0.5 set gsiz 0.35 * V/cr x(10) r 1.1 2.3 3.0 4.4 5.9 5.3 4.6 3.1 2.5 0.9 | data vector V/cr par(3) r 1 2 3 | three parameters: Const, Mean, Sigma V/cr xco1(51) V/cr yco1(51) V/cr xco2(51) V/cr yco2(51) V/cr xco3(51) V/cr yco3(51) V/cr par1sig(3) * cr/tit '1[s] contour (P1 = const, P2 = mean)' zon 2 2 vec/dr x 1 | save data vector into hist. 1 * *--- To run the present example interactively (NOT as a macro), *--- the following commands (from Application ... until Exit) *--- must be given one by one AFTER the Hi/Fit call * * ... get 1-sigma contour: log-likelihood change by 0.5 Application HMINUIT exit Set errordef 0.5 Migrad Minos Show cov Show err Mnc 1 2 C Exit Hi/Fit 1 G LM 3 par | call MINUIT with option L (likelihood) *--- the contour is available in vectors XFIT(51) and YFIT(51) vec/copy par par1sig vec/pri XFIT vec/pri YFIT vec/copy XFIT xco1 vec/copy YFIT yco1 * * ... get 2-sigma contour: log-likelihood change by 2.0 cr/tit '2[s] contour (P1 = const, P2 = mean)' zon 2 2 vec/dr x Application HMINUIT exit Set errordef 2.0 Migrad Minos Show cov Show err Mnc 1 2 C Exit Hi/Fit 1 G LM 3 par | call MINUIT with option L (likelihood) *--- the contour is available in vectors XFIT(51) and YFIT(51) vec/pri XFIT vec/pri YFIT vec/copy XFIT xco2 vec/copy YFIT yco2 * * ... get 3-sigma contour: log-likelihood change by 4.5 cr/tit '3[s] contour (P1 = const, P2 = mean)' zon 2 2 vec/dr x Application HMINUIT exit Set errordef 4.5 Migrad Minos Show cov Show err Mnc 1 2 C Exit Hi/Fit 1 G LM 3 par | call MINUIT with option L (likelihood) *--- the contour is available in vectors XFIT(51) and YFIT(51) vec/pri XFIT vec/pri YFIT vec/copy XFIT xco3 vec/copy YFIT yco3 *** vec/pri par1sig cr/tit '1[s], 2[s] and 3[s] contours' opt grid zon 1 1 null 2.0 10.0 4.0 7.5 | draw empty frame atitle 'P1 (const.)' 'P2 (mean)' dline 5.215 5.215 4.0 7.5 | vertical line representing P1 estimate dline 2.0 10.0 5.815 5.815 | horiz. line representing P2 estimate set plci 4 set lwid 6 graphics/prim/pline 51 xco1 yco1 set plci 6 graphics/prim/pline 51 xco2 yco2 set plci 2 graphics/prim/pline 51 xco3 yco3 ***