//
#include "AliTPCCalibViewer.h"
+using std::ifstream;
ClassImp(AliTPCCalibViewer)
// assignment operator - dummy
// not yet working!!!
//
+ if (this == ¶m) return (*this);
+
fTree = param.fTree;
fTreeMustBeDeleted = param.fTreeMustBeDeleted;
//fFile = new TFile(*(param.fFile));
}
//_____________________________________________________________________________
-void AliTPCCalibViewer::Delete(Option_t* option) {
+void AliTPCCalibViewer::Delete(Option_t* /*option*/) {
//
// Should be called from AliTPCCalibViewerGUI class only.
// If you use Delete() do not call the destructor.
// All objects (except those contained in fListOfObjectsToBeDeleted) will be deleted, the file will be closed.
//
- option = option; // to avoid warnings on compiling
if (fTree && fTreeMustBeDeleted) {
fTree->SetCacheSize(0);
fTree->Delete();
}
- if (fFile)
- delete fFile;
+ delete fFile;
delete fListOfObjectsToBeDeleted;
}
Double_t sig = (str.IsFloat()) ? str.Atof() : 0;
nsigma[i] = sig;
}
-
+ delete sigmasTokens;
+
TString drawStr(drawCommand);
Bool_t dangerousToDraw = drawStr.Contains(":") || drawStr.Contains(">>");
if (dangerousToDraw) {
Double_t sig = (str.IsFloat()) ? str.Atof() : 0;
nsigma[i] = sig;
}
-
+ delete sigmasTokens;
+
if (plotMean) {
cutHistoMean = AliTPCCalibViewer::SigmaCut(htemp, mean, sigma, sigmaMax, sigmaStep, pm);
if (cutHistoMean) {
}
-Int_t AliTPCCalibViewer::SigmaCutNew(const char* drawCommand, const char* sector, const char* cuts, Float_t sigmaMax, Bool_t plotMean, Bool_t plotMedian, Bool_t plotLTM, Bool_t pm, const char *sigmas, Float_t sigmaStep) const {
+Int_t AliTPCCalibViewer::SigmaCutNew(const char* drawCommand, const char* sector, const char* cuts, Float_t /*sigmaMax*/, Bool_t plotMean, Bool_t plotMedian, Bool_t plotLTM, Bool_t /*pm*/, const char *sigmas, Float_t /*sigmaStep*/) const {
//
// Creates a histogram, where you can see, how much of the data are inside sigma-intervals
// around the mean/median/LTM
//
// Double_t ltmFraction = 0.8; //unused
- // avoid compiler warnings:
- sigmaMax = sigmaMax;
- pm = pm;
- sigmaStep = sigmaStep;
TString drawStr(drawCommand);
drawStr += " >> tempHist";
Double_t sig = (str.IsFloat()) ? str.Atof() : 0;
nsigma[i] = sig;
}
+ delete sigmasTokens;
if (plotMean) {
for (Int_t i = 0; i < entries; i++) {
Double_t sig = (str.IsFloat()) ? str.Atof() : 0;
nsigma[i] = sig;
}
-
+ delete sigmasTokens;
+
TLegend * legend = new TLegend(.7,.7, .99, .99, "Integrated histogram");
//fListOfObjectsToBeDeleted->Add(legend);
TH1F *integralHistoMean = 0;
}
-Int_t AliTPCCalibViewer::Integrate(const char* drawCommand, const char* sector, const char* cuts, Float_t sigmaMax, Bool_t plotMean, Bool_t plotMedian, Bool_t plotLTM, const char *sigmas, Float_t sigmaStep) const {
+Int_t AliTPCCalibViewer::Integrate(const char* drawCommand, const char* sector, const char* cuts, Float_t /*sigmaMax*/, Bool_t plotMean, Bool_t plotMedian, Bool_t plotLTM, const char *sigmas, Float_t /*sigmaStep*/) const {
//
// Creates an integrated histogram Begin_Latex S(t, #mu, #sigma) End_Latex, out of the input distribution distribution Begin_Latex f(x, #mu, #sigma) End_Latex, given in "histogram"
// "mean" and "sigma" are Begin_Latex #mu End_Latex and Begin_Latex #sigma End_Latex of the distribution in "histogram", to be specified by the user
*/
Double_t ltmFraction = 0.8;
- // avoid compiler warnings:
- sigmaMax = sigmaMax;
- sigmaStep = sigmaStep;
TString drawStr(drawCommand);
Bool_t dangerousToDraw = drawStr.Contains(":") || drawStr.Contains(">>");
Double_t sig = (str.IsFloat()) ? str.Atof() : 0;
nsigma[i] = sig;
}
-
+ delete sigmasTokens;
+
TLegend * legend = new TLegend(.7,.7, .99, .99, "Integrated histogram");
//fListOfObjectsToBeDeleted->Add(legend);
}
-TH1F* AliTPCCalibViewer::SigmaCut(Int_t n, const Double_t *array, Double_t mean, Double_t sigma, Int_t nbins, const Double_t *xbins, Double_t sigmaMax){
+TH1F* AliTPCCalibViewer::SigmaCut(Int_t /*n*/, const Double_t */*array*/, Double_t /*mean*/, Double_t /*sigma*/, Int_t /*nbins*/, const Double_t */*xbins*/, Double_t /*sigmaMax*/){
//
// SigmaCut for variable binsize
// NOT YET IMPLEMENTED !!!
//
printf("SigmaCut with variable binsize, Not yet implemented\n");
- // avoid compiler warnings:
- n=n;
- mean=mean;
- sigma=sigma;
- nbins=nbins;
- sigmaMax=sigmaMax;
- array=array;
- xbins=xbins;
return 0;
}
fitter->ClearPoints();
Int_t entries = Draw(drawStr.Data(), cutStr.Data(), "goff");
- if (entries == -1) return new TString("An ERROR has occured during fitting!");
+ if (entries == -1) {
+ delete formulaTokens;
+ return new TString("An ERROR has occured during fitting!");
+ }
Double_t **values = new Double_t*[dim+1] ;
for (Int_t i = 0; i < dim + 1; i++){
if (entries != centries) {
delete [] values;
+ delete formulaTokens;
return new TString("An ERROR has occured during fitting!");
}
values[i] = new Double_t[entries];
}
delete fIn;
}
+ delete arrFileLine;
}