/[PAMELA software]/quicklook/tracker/flight/macros/FTrkCalibQLook_EXPERT.cxx
ViewVC logotype

Diff of /quicklook/tracker/flight/macros/FTrkCalibQLook_EXPERT.cxx

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by pam-fi, Thu May 18 13:06:08 2006 UTC revision 1.5 by pam-fi, Thu Jun 8 17:03:57 2006 UTC
# Line 2  Line 2 
2   * FTrkCalibQLookExpert.cpp   * FTrkCalibQLookExpert.cpp
3   *   *
4   * autor: D.Fedele   * autor: D.Fedele
5   * version 2.0   * version 3.0
6   * Parameters:   * Parameters:
7   *      file - the data file to analyze   *      file - the data file to analyze
8   *      step - select =1 in order to analyze one event at time   *      step - select =1 in order to analyze one event at time
# Line 70  void FTrkCalibQLook_EXPERT(TString file, Line 70  void FTrkCalibQLook_EXPERT(TString file,
70    //    //
71    //   obtain information about the data file and select the output dir    //   obtain information about the data file and select the output dir
72    const string filepath=file.Data();    const string filepath=file.Data();
73    Int_t dwpos = filepath.rfind("DW_");    Int_t dwpos = filepath.rfind("/");
74    Int_t dwpos1 = filepath.find(".root");    Int_t dwpos1 = filepath.rfind(".root");
75    TString fpath=(filepath.c_str());    TString fpath=(filepath.c_str());
76    TString base,ffile;    TString base,ffile;
77    stringcopy(base,fpath,0,dwpos);    stringcopy(base,fpath,0,dwpos);
78    stringcopy(ffile,fpath,dwpos,dwpos1);    stringcopy(ffile,fpath,dwpos+1,dwpos1);
79      if(dwpos>0) base+="/";
80    
81    TString out;    TString out;
82    if(outdir.Length()==0){    if(outdir.Length()==0){
# Line 306  void FTrkCalibQLook_EXPERT(TString file, Line 307  void FTrkCalibQLook_EXPERT(TString file,
307      TH1F *histoasig[12];           //histos of sigma      TH1F *histoasig[12];           //histos of sigma
308      TH1F *histoaped[12];          //histos of pedestals      TH1F *histoaped[12];          //histos of pedestals
309            
310      Double_t posy = 0.95;    // up y-coord - top pads      Float_t posy = 0.95;    // up y-coord - top pads
311      Double_t hpad = 0.15;   // pad height      Float_t hpad = 0.15;   // pad height
312      Double_t posx1=0;          // left  x-coord - pad column      Float_t posx1=0;          // left  x-coord - pad column
313      Double_t posx2=0;          // right x-coord - pad olumn      Float_t posx2=0;          // right x-coord - pad olumn
314      Double_t posx0=0;          //       x-coord - column division      Float_t posx0=0;          //       x-coord - column division
315      Double_t wrel = 0.6;     // relative x size of first sub-column      Float_t wrel = 0.6;     // relative x size of first sub-column
316      Double_t marg = 0.004;   // margin among pads      Float_t marg = 0.004;   // margin among pads
317      stringstream title;      stringstream title;
318      stringstream hid;      stringstream hid;
319    
# Line 335  void FTrkCalibQLook_EXPERT(TString file, Line 336  void FTrkCalibQLook_EXPERT(TString file,
336        /* -----------> HISTOGRAMS          */        /* -----------> HISTOGRAMS          */
337        /* calibration parameters */        /* calibration parameters */
338        title<<"DSP "<<n+1;        title<<"DSP "<<n+1;
339        hid<<"h"<<n;        hid<<"h"<<n<<"i"<<i;
340        histosig[n] = new TH1F(hid.str().c_str(),title.str().c_str(),3072,0.5,3072.5);        histosig[n] = new TH1F(hid.str().c_str(),title.str().c_str(),3072,0.5,3072.5);
341        hid.str("");        hid.str("");
342        hid<<"hh"<<n;        hid<<"hh"<<n<<"i"<<i;
343        histoped[n] = new TH1F(hid.str().c_str(),title.str().c_str(),3072,0.5,3072.5);        histoped[n] = new TH1F(hid.str().c_str(),title.str().c_str(),3072,0.5,3072.5);
344        hid.str("");        hid.str("");
345        hid<<"hhh"<<n;        hid<<"hhh"<<n<<"i"<<i;
346        title.str("");        title.str("");
347        hid.str("");        hid.str("");
348        /* AVERAGE calibration parameters */            /* AVERAGE calibration parameters */    
349        hid<<"ah"<<n;        hid<<"ah"<<n<<"i"<<i;
350        histoasig[n] = new TH1F(hid.str().c_str(),title.str().c_str(),3,0.5,3072.5);        histoasig[n] = new TH1F(hid.str().c_str(),title.str().c_str(),3,0.5,3072.5);
351        hid.str("");        hid.str("");
352        hid<<"ahh"<<n;        hid<<"ahh"<<n<<"i"<<i;
353        histoaped[n] = new TH1F(hid.str().c_str(),title.str().c_str(),3,0.5,3072.5);        histoaped[n] = new TH1F(hid.str().c_str(),title.str().c_str(),3,0.5,3072.5);
354        hid.str("");        hid.str("");
355      };                     //end loop on views      };                     //end loop on views
# Line 453  void FTrkCalibQLook_EXPERT(TString file, Line 454  void FTrkCalibQLook_EXPERT(TString file,
454        li.SetLineStyle(3);        li.SetLineStyle(3);
455        li.SetLineWidth(2);        li.SetLineWidth(2);
456                
457        Double_t maxhist=0;        Float_t maxhist=0;
458        TBox b;        TBox b;
459        b.SetFillColor(6);        b.SetFillColor(6);
460        b.SetFillStyle(3945);        b.SetFillStyle(3945);
# Line 504  void FTrkCalibQLook_EXPERT(TString file, Line 505  void FTrkCalibQLook_EXPERT(TString file,
505    
506                
507        /* plot SIGMA */        /* plot SIGMA */
508        Double_t max=500.;        Float_t max=500.;
509        c2->cd();        c2->cd();
510        trkpadtext[nn]->Draw();        trkpadtext[nn]->Draw();
511        trkpad2[nn]->SetLogy();        trkpad2[nn]->SetLogy();

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.5

  ViewVC Help
Powered by ViewVC 1.1.23