Heavy ion Analysis Libriares
Loading...
Searching...
No Matches
CorrFitPainter.h
1/*
2 * CorrFitPainter.h
3 *
4 * Created on: 23 lip 2024
5 * Author: daniel
6 */
7
8#ifndef HAL_ANALYSIS_FEMTO_PAINTERS_CORRFITPAINTER_H_
9#define HAL_ANALYSIS_FEMTO_PAINTERS_CORRFITPAINTER_H_
10
11#include <Rtypes.h>
12#include <RtypesCore.h>
13#include <TF1.h>
14#include <TLegendEntry.h>
15#include <TString.h>
16#include <array>
17#include <initializer_list>
18#include <vector>
19
20#include "Painter.h"
21
22class TLegend;
23class TVirtualPad;
24namespace Hal {
31 class CorrFitFunc;
32 class FemtoCFPainter;
33 class CorrFitPainter : public Painter {
34 protected:
35 Int_t fNormIndex = {-1};
36 TLegend* fLegend = {nullptr};
37 TVirtualPad* fLegendPad = {nullptr};
38 TString fDefFuncDrawOpt = "SAME";
39 std::array<Double_t, 4> fLegendPos = {0.7, 0.95, 0.7, 0.95};
40 std::vector<TLegendEntry*> fLegendEntries;
41 static const int kAutoNormBit, kLegendBit, kChi2, kChi2Short;
51 virtual ULong64_t SetOptionInternal(TString opt, ULong64_t prev = 0);
52 std::vector<std::vector<TF1*>> fFunctions;
53 CorrFitFunc* fFittedFunc = {nullptr};
54 FemtoCFPainter* fCFPainter = {nullptr};
55
56 virtual void MakePadsAndCanvases() {};
57 virtual void UpdateParameters() = 0;
58 virtual void MakeFunctions() = 0;
59 virtual void ScaleFunctions();
60 virtual void ScaleHistograms();
61 virtual void DrawFunctions();
62 virtual void MakeLegend();
63 virtual void UpdateLegend();
64 void DeleteFunctions();
65 std::vector<TString> GetLegendLabels() const;
66 ULong64_t PrepBitTemplate(std::initializer_list<int> temps) const;
73 Bool_t AreSimiliar(ULong64_t current, ULong64_t pattern) const;
74 virtual void InnerPaint();
75 virtual void InnerRepaint();
76
77 public:
78 CorrFitPainter(CorrFitFunc* func = nullptr);
79 virtual ~CorrFitPainter();
80 ClassDef(CorrFitPainter, 0)
81 };
82
83} /* namespace Hal */
84
85#endif /* HAL_ANALYSIS_FEMTO_PAINTERS_CORRFITPAINTER_H_ */
virtual ULong64_t SetOptionInternal(TString opt, ULong64_t prev=0)
virtual void InnerRepaint()
Bool_t AreSimiliar(ULong64_t current, ULong64_t pattern) const
virtual void MakePadsAndCanvases()
virtual void InnerPaint()