/* * TwoWireGraphAnalyzer.hh * * Created on: Apr 24, 2015 * Author: Hovanes Egiyan */ #ifndef TWOWIREGRAPHANALYZER_HH_ #define TWOWIREGRAPHANALYZER_HH_ #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include "GraphAnalyzer.hh" class TwoWireGraphAnalyzer: public GraphAnalyzer { protected: TF1* twgaFitFun; // Map to give the lower and upper range for analysis // The first string key indicates the label (X or Y) // The second string key indicates the low or high edge static map > twgaFitRange; TGraphErrors* twgaSubGraph; virtual void CreateSubGraph(); virtual void CreateFitFun( string funName, double xMin, double xMax ); virtual void FindInitialParValues(); public: TwoWireGraphAnalyzer(TGraphErrors* graph, string sName, string label ); TwoWireGraphAnalyzer( const TwoWireGraphAnalyzer& analyzer ); virtual ~TwoWireGraphAnalyzer(); virtual TFitResultPtr FitGraph() ; static double TwoWireScanFitFun( double* x, double* params ); static map > InitRanges(); virtual void Draw( Option_t* opt) ; inline virtual TF1* GetFitFunction() { return twgaFitFun; } inline static map > GetFitRange() {return twgaFitRange;} // ClassDef(TwoWireGraphAnalyzer,0) }; #endif /* TWOWIREGRAPHANALYZER_HH_ */