GRUTinizer
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
include
TPeakFinder.h
Go to the documentation of this file.
1
#ifndef TPEAKFINDER_H
2
#define TPEAKFINDER_H
3
4
#include <iostream>
5
#include <string>
6
#include <fstream>
7
#include <cstdio>
8
#include <sstream>
9
10
#include "TObject.h"
11
#include "TList.h"
12
#include "TFile.h"
13
#include "TClass.h"
14
#include "TKey.h"
15
#include "TSpectrum.h"
16
#include "TH1.h"
17
#include "TH2.h"
18
#include "TGraphErrors.h"
19
#include "TMath.h"
20
#include "TCanvas.h"
21
#include "TPaveText.h"
22
#include "TRandom.h"
23
24
#include "
TNucleus.h
"
25
#include "
ProgramPath.h
"
26
27
class
TPeakFinder
:
public
TObject{
28
public
:
29
TPeakFinder
(
TNucleus
*nucl);
30
~TPeakFinder
();
31
void
Clear
(Option_t *opt=
""
);
32
void
Print
(Option_t *opt=
""
)
const
;
33
34
TH1 *
GetBackground
(TH1* hist);
35
TH1 *
GetBgSub
(TH1* hist);
36
TH1 *
GetScaled
(TH1* hist,Double_t cal);
37
TH1 *
GetBackground
()
const
{
if
(
hBkgd
)
return
hBkgd
;
else
return
0;}
38
TH1 *
GetBgSub
()
const
{
if
(
hBkgdSub
)
return
hBkgdSub
;
else
return
0;}
39
TH1 *
GetScaled
()
const
{
if
(
hScaled
)
return
hScaled
;
else
return
0;}
40
Double_t
GetPeaksForFit
() {
return
fPeakNum
; }
41
TNucleus
*
GetNucleus
()
const
{
return
tnNucleus
; }
42
43
44
//TSpectrum *LocatePeaks(TH1* hist,Double_t sigma=2.0,Double_t thresh=0.2);
45
//void OrderPeaks(TSpectrum* Spec,Double_t &XVal,Double_t &YVal,Bool_t LowToHigh=true);
46
47
48
49
50
private
:
51
Bool_t
PeaksForFit
();
// Only call this in the constructor.
52
std::vector<Double_t>
fPeaksToFit
;
53
Double_t
fPeakNum
;
54
TNucleus
*
tnNucleus
;
55
TH1 *
hBkgd
;
56
TH1 *
hBkgdSub
;
57
TH1 *
hScaled
;
58
ClassDef
(
TPeakFinder
,1);
59
};
60
61
62
63
#endif
Generated on Wed Nov 4 2015 17:27:53 for GRUTinizer by
1.8.1.2