/[PAMELA software]/PamCut/CollectionActions/RigFillAction/RigFillAction.cpp
ViewVC logotype

Diff of /PamCut/CollectionActions/RigFillAction/RigFillAction.cpp

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

revision 1.5 by pam-fi, Tue Oct 27 10:18:21 2009 UTC revision 1.6 by pam-fi, Mon Mar 8 09:17:58 2010 UTC
# Line 68  void RigFillAction::OnGood(PamLevel2 *ev Line 68  void RigFillAction::OnGood(PamLevel2 *ev
68    float rigThreshold = _thresholdCoeff * event->GetOrbitalInfo()->GetCutoffSVL();    float rigThreshold = _thresholdCoeff * event->GetOrbitalInfo()->GetCutoffSVL();
69    float rig = event->GetTrack(0)->GetTrkTrack()->GetRigidity();    float rig = event->GetTrack(0)->GetTrkTrack()->GetRigidity();
70    
71    _rootHisto.Fill(rigThreshold, rig); // X,Y in the ROOT histogram    //_rootHisto.Fill(rigThreshold, rig); // X,Y in the ROOT histogram
72    
73    // Event rigidity bin identification.    // Event rigidity bin identification.
74    
# Line 84  void RigFillAction::OnGood(PamLevel2 *ev Line 84  void RigFillAction::OnGood(PamLevel2 *ev
84    
85    // Threshold rigidity bin identification.    // Threshold rigidity bin identification.
86    
87    if (rigThreshold < 0 || rigThreshold >= _bins[(int) _textHisto.GetNRows()]) {    if (rigThreshold <= 0 || rigThreshold >= _bins[(int) _textHisto.GetNRows()]) {
88      return;      return;
89    }    }
90    
91    if (0 <= rigThreshold && rigThreshold < _bins[0])    if (0 < rigThreshold && rigThreshold < _bins[0])
92      _zeroCutoffBins[i]++;      _zeroCutoffBins[i]++;
93    else {    else {
94      int j = 1;      int j = 1;
# Line 124  void RigFillAction::Finalize() { Line 124  void RigFillAction::Finalize() {
124      outTextFile.close();      outTextFile.close();
125    
126      // Write the ROOT file      // Write the ROOT file
127      TFile outRootFile((_outFileBase + "-" + GetName() + ".root"), "RECREATE");      /*TFile outRootFile((_outFileBase + "-" + GetName() + ".root"), "RECREATE");
128      outRootFile.cd();       outRootFile.cd();
129      _rootHisto.Write();       _rootHisto.Write();
130      outRootFile.Close();       outRootFile.Close();
131         */
132    }    }
133  }  }

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

  ViewVC Help
Powered by ViewVC 1.1.23