From 23bb6a9c5f6f1df4729836fc89327e3ad34eeca0 Mon Sep 17 00:00:00 2001 From: mfloris Date: Wed, 13 Mar 2013 13:03:42 +0000 Subject: [PATCH] Adding mean ranges --- PWGLF/SPECTRA/PiKaPr/COMBINED/FitParticle.C | 6 +++--- PWGLF/SPECTRA/PiKaPr/COMBINED/SpectraUtils.C | 10 ++++++---- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/PWGLF/SPECTRA/PiKaPr/COMBINED/FitParticle.C b/PWGLF/SPECTRA/PiKaPr/COMBINED/FitParticle.C index 166528fd493..b5fa94d4d90 100644 --- a/PWGLF/SPECTRA/PiKaPr/COMBINED/FitParticle.C +++ b/PWGLF/SPECTRA/PiKaPr/COMBINED/FitParticle.C @@ -22,7 +22,7 @@ using namespace std; enum {kFitExpPt, kFitLevi, fFitExpMt, kFitBoltzmann, kFitBlastWave, kFitBoseEinstein, kFitFermiDirac}; Bool_t skipMean = 0; -void FitParticle(TH1 * h, const char * partName, Float_t min = 0, Float_t max =3, Float_t scaleHisto = -1., Int_t fitFunc = kFitLevi, Int_t vartype = AliPWGFunc::kdNdpt, const char * fileOut = 0, Bool_t wait = 0) ; +void FitParticle(TH1 * h, const char * partName, Float_t min = 0, Float_t max =3, Float_t scaleHisto = -1., Int_t fitFunc = kFitLevi, Int_t vartype = AliPWGFunc::kdNdpt, const char * fileOut = 0, Bool_t wait = 0, Float_t meanMin = 0., Float_t meanMax = 100) ; void FitParticle(const char * file, const char * histo, const char * partName, const char * listname=0, Float_t min = 0, Float_t max =3, Float_t scaleHisto = -1., Int_t fitFunc = kFitLevi, Int_t vartype = AliPWGFunc::kdNdpt, const char * fileOut = 0, Bool_t wait = 0); void FitParticle(const char * file, const char * histo, const char * partName, const char * listname, Float_t min, Float_t max, Float_t scaleHisto, Int_t fitFunc, Int_t vartype, const char * fileOut, Bool_t wait) { @@ -78,7 +78,7 @@ void FitParticle(const char * file, const char * histo, const char * partName, } -void FitParticle(TH1 * h, const char * partName, Float_t min , Float_t max, Float_t scaleHisto, Int_t fitFunc, Int_t vartype, const char * fileOut, Bool_t wait) { +void FitParticle(TH1 * h, const char * partName, Float_t min , Float_t max, Float_t scaleHisto, Int_t fitFunc, Int_t vartype, const char * fileOut, Bool_t wait, Float_t meanMin, Float_t meanMax) { // get histo and draw @@ -233,7 +233,7 @@ void FitParticle(TH1 * h, const char * partName, Float_t min , Float_t max, Floa Double_t mean=0, meane=0; // Float_t mean2=0, mean2e=0; // AliPWGHistoTools::GetMean (func, mean, meane , 0.,100., normPar); - AliPWGHistoTools::GetMeanDataAndExtrapolation (h, func, mean, meane , 0.,100.); + AliPWGHistoTools::GetMeanDataAndExtrapolation (h, func, mean, meane , meanMin, meanMax); // AliPWGHistoTools::GetMeanDataAndExtrapolation (h, func, mean, meane , 0.,4.5); // AliPWGHistoTools::GetMeanSquare(func, mean2, mean2e, 0.,100., normPar); if(skipMean) table->SetNextCol("N/A"); diff --git a/PWGLF/SPECTRA/PiKaPr/COMBINED/SpectraUtils.C b/PWGLF/SPECTRA/PiKaPr/COMBINED/SpectraUtils.C index a3887253e7c..8c9df578893 100644 --- a/PWGLF/SPECTRA/PiKaPr/COMBINED/SpectraUtils.C +++ b/PWGLF/SPECTRA/PiKaPr/COMBINED/SpectraUtils.C @@ -315,7 +315,7 @@ TF1 *fBGBW[1000]; TGraphErrors *gBW[1000]; TObjArray * -BGBlastWave_GlobalFit(TObjArray *data, Double_t *mass, Double_t profile = .7, Bool_t fixProfile = kFALSE) +BGBlastWave_GlobalFit(TObjArray *data, Double_t *mass, Double_t profile = .9, Bool_t fixProfile = kFALSE) { /* get data */ @@ -351,8 +351,10 @@ BGBlastWave_GlobalFit(TObjArray *data, Double_t *mass, Double_t profile = .7, Bo minuit->mnexcm("SET ERR", arglist, 1, ierflg); for (Int_t idata = 0; idata < nBW; idata++) minuit->mnparm(idata, Form("norm%d", idata), 1.e6, 1., 0., 0., ierflg); - minuit->mnparm(nBW + 0, "", 0.65, 0.01, 0., 1., ierflg); - minuit->mnparm(nBW + 1, "T", 0.1, 0.01, 0., 1., ierflg); + // minuit->mnparm(nBW + 0, "", 0.65, 0.01, 0., 1., ierflg); + // minuit->mnparm(nBW + 1, "T", 0.1, 0.01, 0., 1., ierflg); + minuit->mnparm(nBW + 0, "", 0.55, 0.01, 0., 1., ierflg); + minuit->mnparm(nBW + 1, "T", 0.13, 0.01, 0., 1., ierflg); minuit->mnparm(nBW + 2, "n", profile, 0.1, 0., 10., ierflg); if (fixProfile) minuit->FixParameter(nBW + 2); @@ -414,7 +416,7 @@ BGBlastWave_GlobalFit(TObjArray *data, Double_t *mass, Double_t profile = .7, Bo /* 1-sigma contour */ minuit->SetErrorDef(1); TGraph *gCont1 = NULL; - gCont1 = (TGraph *) minuit->Contour(50, nBW + 0, nBW + 1); + // gCont1 = (TGraph *) minuit->Contour(50, nBW + 0, nBW + 1); if (gCont1) gCont1->SetName("gCont1"); /* 2-sigma contour */ -- 2.43.0