23 #ifndef GW_BASECALIB_H
24 #define GW_BASECALIB_H
35 #ifndef ROOT_TGRAPHERRORS_H
36 #include "TGraphErrors.h"
41 #ifndef GW_H1CALIBRATOR_H
63 void AlignMax(TH1 *
histo, TF1 *
function,
const Double_t AlignValue,
64 const Bool_t invert=
false,
const Double_t xmin=0,
const Double_t xmax=0);
67 void AlignMax(TH1 *histo, TF1 *
function,
const Double_t AlignValue,
68 const Double_t ProportionalCoef,
const Bool_t invert=
false,
const Double_t xmin=0,
const Double_t xmax=0);
70 void SetPoint(
const Int_t index,
const Double_t channel,
const Double_t energy) { fTabulated[index] = energy; fRaw[index] = channel; }
71 void AddPoint(
const Double_t channel,
const Double_t energy);
74 void SetEnergy(
const Int_t index,
const Double_t energy) { fTabulated[index] = energy; }
75 void SetChannel(
const Int_t index,
const Double_t channel) { fRaw[index] = channel; }
77 Double_t
GetEnergy(
const Int_t index)
const {
return fTabulated[index]; }
78 Double_t
GetChannel(
const Int_t index)
const {
return fRaw[index]; }
80 void Calibrate(TF1 *
function)
const;
81 void Calibrate(
const char* filename, TF1 *
function);
82 void Calibrate(TF1 *
function,
const Int_t nbpoints,
const Double_t *raw,
const Double_t *tabulated);
83 void Calibrate(Int_t dimension);
85 void DrawResults(
const TF1 *
function)
const;
87 static void CheckCalibration(TH1 *histo,
const Double_t
value, Double_t xmin=-1111, Double_t xmax=-1111,
const Int_t color=2);
88 static void CheckCalibration(TH1 *histo,
const Int_t nbvalue,
const Double_t *values, Double_t xmin=-1111, Double_t xmax=-1111,
const Int_t color=2);
89 static void CheckCalibration(TH1 *histo,
const char *SourceName, Double_t xmin=-1111, Double_t xmax=-1111,
const Int_t color=2);
void SetPoint(const Int_t index, const Double_t channel, const Double_t energy)
Double_t GetEnergy(const Int_t index) const
Double_t GetChannel(const Int_t index) const
BaseCalib is a tool class.
void SetChannel(const Int_t index, const Double_t channel)
H1Calibrator is a service class in order to calibrate a TH1 The raw histogram must never be changed T...
void SetEnergy(const Int_t index, const Double_t energy)
Get/Set energy/channel.
header file for the calibration facility