00001
00002
00004 #ifndef __ffl__
00005 #define __ffl__
00006
00007 #include "ReadAscii.h"
00008 #include "GwollumPlot.h"
00009 #include "Segments.h"
00010 #include "TGraph.h"
00011 #include "FrameL.h"
00012 #include "FrVect.h"
00013
00014 using namespace std;
00015
00033 class ffl {
00034
00035 public:
00036
00048 ffl(const string aFrameFileList, const string aPlotStyle="GWOLLUM", const int aVerbosity=0);
00049
00053 virtual ~ffl(void);
00065 bool DefineTmpDir(const string aTmpDirPath=".");
00066
00075 bool LoadFrameFile(void);
00076
00092 double* GetData(int &aSize, const string channel_name, const double gps_start, const double gps_end);
00093
00102 bool PrintAsciiData(const string channel_name, const double gps_start, const double gps_end, string outputfilename);
00103
00111 TGraph* PlotData(const string channel_name, const double gps_start, const double gps_end);
00112 TGraph* PlotData2(const string channel_name1, const string channel_name12, const double gps_start, const double gps_end);
00113
00121 TGraph* PlotDerivative(const string channel_name, const double gps_start, const double gps_end);
00122
00129 string Convert2Ffl(void);
00130
00137 bool ExtractChannels(const int gps=0);
00138
00146 int GetChannelSampling(const string channel_name);
00147
00152 inline Segments* GetSegments(void){ return seg; }
00153
00157 void Reset(void);
00158
00166 inline void PrintChannels(const int gps=0){
00167 LoadFrameFile();
00168 ExtractChannels(gps);
00169 for(int l=0; l<(int)channels.size(); l++) cout<<channels[l]<<" "<<sampling[l]<<endl;
00170 };
00171
00172 private:
00173
00174 bool status_OK;
00175 string fInFrameFile;
00176 string fWoFrameFile;
00177 string fFormat;
00178 int fVerbosity;
00179 string tmpdir;
00180 string srandint;
00181
00182 vector<double> start;
00183 vector<double> stop;
00184 vector<string> ffile;
00185 Segments *seg;
00186 FrFile *frfile;
00187 vector <string> channels;
00188 vector <int> sampling;
00189
00190
00191 GwollumPlot *GP;
00192 TGraph *G;
00193
00194 bool CheckFFL(void);
00195
00196 ClassDef(ffl,0)
00197
00198 };
00199
00200 #endif
00201
00202