BagTreeAna Class Reference

Calculate PID from Tree or Cut methods and perform classification. More...

#include <BagTreeAna.h>

List of all members.

Public Member Functions

 BagTreeAna (NueRecord &nr, BagTree &tp)
virtual ~BagTreeAna ()
void Analyze ()
void Reset ()

Private Member Functions

 BagTreeAna (const BagTreeAna &rhs)
BagTreeAnaoperator= (const BagTreeAna &rhs)

Private Attributes

NueRecordnueRec
BagTreefbt

Static Private Attributes

static DecisionTreeReader heBag

Detailed Description

Calculate PID from Tree or Cut methods and perform classification.

Version:
Revision
1.1
Date:
Date
2007/10/22 15:59:27

Created on: Thu Mar 16 20:10:10 2006

Id
BagTreeAna.cxx,v 1.1 2007/10/22 15:59:27 boehm Exp

Author: Mayly Sanchez (msanchez@minos.phy.tufts.edu)

Version:
Revision
1.1
Date:
Date
2007/10/22 15:59:27

Created on: Thu Mar 16 19:54:12 2006

Id
BagTreeAna.h,v 1.1 2007/10/22 15:59:27 boehm Exp

Definition at line 31 of file BagTreeAna.h.


Constructor & Destructor Documentation

BagTreeAna::BagTreeAna ( NueRecord nr,
BagTree tp 
)

Definition at line 28 of file BagTreeAna.cxx.

00028                                                 :
00029     nueRec(nr),
00030     fbt(tp)
00031 {
00032    static bool first = true;
00033    if(first){
00034 //     if(!heBag.CreateFromFile("/afs/fnal.gov/files/home/room3/boehm/NueAnaRuns/TreeReader/Test/BagTree_l5_n500_c5.txt"));
00035 
00036      first = false;
00037    }
00038 
00039 
00040 
00041 }

BagTreeAna::~BagTreeAna (  )  [virtual]

Definition at line 43 of file BagTreeAna.cxx.

00044 {}

BagTreeAna::BagTreeAna ( const BagTreeAna rhs  )  [private]

Member Function Documentation

void BagTreeAna::Analyze (  ) 

Definition at line 46 of file BagTreeAna.cxx.

References AnalysisInfoNue::abtrackphmean, NueRecord::anainfo, SubShowerVar::E2to1U, SubShowerVar::E2to1V, MSTCalc::eb1, FracVar::fract_10_counters, FracVar::fract_12_counters, FracVar::fract_3_planes, FracVar::fract_4_counters, FracVar::fract_4_planes, FracVar::fract_5_planes, FracVar::fract_6_planes, FracVar::fract_8_counters, FracVar::fract_road, NueRecord::fracvars, NueRecord::mstvars, nueRec, MSTCalc::ob1, Shwfit::par_b, SubShowerVar::PHAvgIDU, SubShowerVar::PHAvgIDV, SubShowerVar::PHAvgProbEMU, SubShowerVar::PHAvgProbEMV, ANtpShowerInfo::planes, ANtpEventInfo::planes, NueRecord::shwfit, NueRecord::srevent, NueRecord::srshower, NueRecord::srtrack, NueRecord::subshowervars, ANtpTrackInfoNue::trklikePlanes, Shwfit::u_molrad_peak, Shwfit::UBeamLike, Shwfit::uv_kurt, Shwfit::uv_molrad_peak, Shwfit::uv_rms, Shwfit::uv_skew, Shwfit::v_molrad_peak, and Shwfit::VBeamLike.

Referenced by NueRecordAna::Analyze().

00047 {
00048     NueRecord *nr=&nueRec;
00049 
00050    Double_t AvgIDU,AvgIDV,AvgProbEMU,AvgProbEMV;
00051    double E2to1U, E2to1V; //, ubeam, vbeam;                                                                               
00052    double fract_road;
00053    double fv_3_planes, fv_4_planes, fv_5_planes, fv_6_planes;
00054    double fv_4_count, fv_8_count, fv_10_count, fv_12_count;
00055    double abtrackphmean;
00056    double uv_molrad_sum;
00057    double uvbeam;
00058    double uvbeamsum;
00059    double SSVar1, SSVar2, SSVar3;
00060    double mstVar1;
00061    double SSVar4, SSVar5;
00062    double trkrat, shwrat;
00063    double ob1, eb1;
00064                                                                                 
00065    double  input[30];
00066                                                                                 
00067 
00068     int evtplanes = nr->srevent.planes;
00069     int shwplanes = nr->srshower.planes;
00070     int trklikeplanes = nr->srtrack.trklikePlanes;
00071                                                                                 
00072     trkrat = shwrat = 0;
00073     if(evtplanes > 0){
00074              trkrat = double(trklikeplanes)/double(evtplanes);
00075              shwrat = double(shwplanes)/double(evtplanes);
00076     }
00077                                                                                
00078     double t1 = nr->shwfit.UBeamLike;
00079     double t2 = nr->shwfit.VBeamLike;
00080     if(t1 < -1000) uvbeam = uvbeamsum = t1;
00081     else if(t2 < -1000) uvbeam = uvbeamsum = t2;
00082     else{   uvbeam = t1*t2;   uvbeamsum= t1 + t2;    }
00083                                                                                 
00084     t2 = nr->shwfit.u_molrad_peak;
00085     t2 = nr->shwfit.v_molrad_peak;
00086                                                                                
00087     if(t1 < -1000) uv_molrad_sum = t1;
00088     else if(t2 < -1000) uv_molrad_sum = t2;
00089     else{   uv_molrad_sum = t1 + t2;          }
00090                                                                                 
00091     fract_road = nr->fracvars.fract_road;
00092     fv_3_planes = nr->fracvars.fract_3_planes;
00093     fv_4_planes = nr->fracvars.fract_4_planes;
00094     fv_5_planes = nr->fracvars.fract_5_planes;
00095     fv_6_planes = nr->fracvars.fract_6_planes;
00096     fv_4_count = nr->fracvars.fract_4_counters;
00097     fv_8_count = nr->fracvars.fract_8_counters;
00098     fv_10_count = nr->fracvars.fract_10_counters;
00099     fv_12_count = nr->fracvars.fract_12_counters;
00100             abtrackphmean = nr->anainfo.abtrackphmean;
00101                                                                                 
00102             AvgIDU = nr->subshowervars.PHAvgIDU;
00103             AvgIDV = nr->subshowervars.PHAvgIDV;
00104             AvgProbEMU = nr->subshowervars.PHAvgProbEMU;
00105             AvgProbEMV = nr->subshowervars.PHAvgProbEMV;
00106             E2to1U = nr->subshowervars.E2to1U;
00107             E2to1V = nr->subshowervars.E2to1V;
00108             ob1 = nr->mstvars.ob1;
00109             eb1 = nr->mstvars.eb1;
00110       SSVar1 = SSVar2 = SSVar3 = SSVar4 = SSVar5 = -9999;
00111             mstVar1 = -9999;
00112                                                                                 
00113             if(AvgIDU > -1000 &&  AvgIDV > -1000) SSVar1 = AvgIDU + AvgIDV;
00114             if(AvgProbEMU > -1000 && AvgProbEMV > -1000){
00115               SSVar2 = AvgProbEMU*AvgProbEMU + AvgProbEMV*AvgProbEMV;
00116               SSVar3 = AvgProbEMU + AvgProbEMV;
00117             }
00118             if(E2to1U > -1000 && E2to1V > -1000){
00119               SSVar4 = E2to1U + E2to1V;
00120               SSVar5 = E2to1V*E2to1V + E2to1U*E2to1U;
00121             }
00122                                                                                 
00123      if(ob1 > -1000 && eb1 > -1000)
00124                mstVar1 = ob1*ob1 + eb1*eb1;
00125                                                                                 
00126                                                                                 
00127      input[0] =   nr->shwfit.uv_molrad_peak;
00128      input[1] =   nr->shwfit.uv_kurt;
00129      input[2] =  nr->fracvars.fract_road;
00130      input[3] =  nr->fracvars.fract_3_planes;
00131      input[4] =    fv_4_planes;
00132      input[5] =    fv_5_planes;
00133      input[6] =    fv_6_planes;
00134      input[7] =    fv_4_count;
00135      input[8] =    fv_8_count;
00136      input[9] =    fv_10_count;
00137      input[10] =   fv_12_count;
00138      input[11] =    nr->shwfit.uv_skew;
00139      input[12] =  abtrackphmean;
00140      input[13] =   uv_molrad_sum;
00141      input[14] =    uvbeam;
00142      input[15] =  uvbeamsum;
00143      input[16] =    nr->shwfit.par_b;
00144      input[17] =   nr->shwfit.uv_rms;
00145      input[18] =   SSVar1;
00146      input[19] =   SSVar2;
00147      input[20] =   SSVar3;
00148      input[21] =  SSVar4;
00149      input[22] =   SSVar5;
00150      input[23] =   mstVar1;
00151      input[24] =   trkrat;
00152      input[25] =   shwrat;
00153      input[26] =    ob1;
00154      input[27] =    eb1;
00155  
00156 //     fbt.hePID = heBag.Evaluate(input,28);
00157                             
00158 }

BagTreeAna& BagTreeAna::operator= ( const BagTreeAna rhs  )  [private]
void BagTreeAna::Reset (  ) 

Definition at line 160 of file BagTreeAna.cxx.

00161 {}


Member Data Documentation

Definition at line 44 of file BagTreeAna.h.

Definition at line 49 of file BagTreeAna.h.

Definition at line 43 of file BagTreeAna.h.

Referenced by Analyze().


The documentation for this class was generated from the following files:

Generated on 22 Nov 2017 for loon by  doxygen 1.6.1