CMS 3D CMS Logo

Public Types | Public Member Functions | Public Attributes

TMTQ Class Reference

#include <TMTQ.h>

List of all members.

Public Types

enum  outVar {
  iPeak, iSigma, iFit, iAmpl,
  iTrise, iFwhm, iFw20, iFw80,
  iPed, iPedsig, iSlide, nOutVar
}

Public Member Functions

void addEntry (double, double, double, double, double, double, double, double, double, double, double)
std::vector< double > get (int)
std::vector< double > getAmpl ()
std::vector< double > getFit ()
std::vector< double > getFw20 ()
std::vector< double > getFw80 ()
std::vector< double > getFwhm ()
std::vector< double > getPeak ()
std::vector< double > getPed ()
std::vector< double > getPedsig ()
std::vector< double > getSigma ()
std::vector< double > getSliding ()
std::vector< double > getTrise ()
void init ()
void setCut (int, double, double)
 TMTQ ()
virtual ~TMTQ ()

Public Attributes

double cuts [2][nOutVar]
TMommom [nOutVar]

Detailed Description

Definition at line 8 of file TMTQ.h.


Member Enumeration Documentation

Enumerator:
iPeak 
iSigma 
iFit 
iAmpl 
iTrise 
iFwhm 
iFw20 
iFw80 
iPed 
iPedsig 
iSlide 
nOutVar 

Definition at line 14 of file TMTQ.h.


Constructor & Destructor Documentation

TMTQ::TMTQ ( )

Definition at line 19 of file TMTQ.cc.

References init.

{
  init();
}
TMTQ::~TMTQ ( ) [virtual]

Definition at line 26 of file TMTQ.cc.

{
}

Member Function Documentation

void TMTQ::addEntry ( double  peak,
double  sigma,
double  fit,
double  ampl,
double  trise,
double  fwhm,
double  fw20,
double  fw80,
double  ped,
double  pedsig,
double  sliding 
)

Definition at line 40 of file TMTQ.cc.

{
  double val[nOutVar];

  val[iPeak]=peak;
  val[iSigma]=sigma;
  val[iFit]=fit;
  val[iAmpl]=ampl;
  val[iTrise]=trise;
  val[iFwhm]=fwhm;
  val[iFw20]=fw20;
  val[iFw80]=fw80;
  val[iPed]=ped;
  val[iPedsig]=pedsig;
  val[iSlide]=sliding;

  for(int ivar=0;ivar<nOutVar;ivar++){
    mom[ivar]->addEntry(val[ivar]);
  }

}
std::vector< double > TMTQ::get ( int  ivar)

Definition at line 72 of file TMTQ.cc.

Referenced by EcalMatacqAnalyzer::endJob().

                                   { 

  std::vector<double> res;
  
  if(ivar<nOutVar){

    res.push_back(mom[ivar]->getMean());
    res.push_back(mom[ivar]->getRMS());
    res.push_back(mom[ivar]->getM3());
    res.push_back(mom[ivar]->getNevt());
    res.push_back(mom[ivar]->getMin());
    res.push_back(mom[ivar]->getMax());

  }
  return res;

}
std::vector< double > TMTQ::getAmpl ( )

Definition at line 91 of file TMTQ.cc.

References iAmpl, and x.

{std::vector<double> x=get(TMTQ::iAmpl); return x;}
std::vector< double > TMTQ::getFit ( )

Definition at line 94 of file TMTQ.cc.

References iFit, and x.

{std::vector<double> x=get(TMTQ::iFit); return x;}
std::vector< double > TMTQ::getFw20 ( )

Definition at line 96 of file TMTQ.cc.

References iFw20, and x.

{std::vector<double> x=get(TMTQ::iFw20); return x;}
std::vector< double > TMTQ::getFw80 ( )

Definition at line 97 of file TMTQ.cc.

References iFw80, and x.

{std::vector<double> x=get(TMTQ::iFw80); return x;}
std::vector< double > TMTQ::getFwhm ( )

Definition at line 95 of file TMTQ.cc.

References iFwhm, and x.

{std::vector<double> x=get(TMTQ::iFwhm); return x;}
std::vector< double > TMTQ::getPeak ( )

Definition at line 90 of file TMTQ.cc.

References iPeak, and x.

{std::vector<double> x=get(TMTQ::iPeak); return x;}
std::vector< double > TMTQ::getPed ( )

Definition at line 98 of file TMTQ.cc.

References iPed, and x.

{std::vector<double> x=get(TMTQ::iPed); return x;}
std::vector< double > TMTQ::getPedsig ( )

Definition at line 99 of file TMTQ.cc.

References iPedsig, and x.

{std::vector<double> x=get(TMTQ::iPedsig); return x;}
std::vector< double > TMTQ::getSigma ( )

Definition at line 92 of file TMTQ.cc.

References iSigma, and x.

{std::vector<double> x=get(TMTQ::iSigma); return x;}
std::vector< double > TMTQ::getSliding ( )

Definition at line 100 of file TMTQ.cc.

References iSlide, and x.

{std::vector<double> x=get(TMTQ::iSlide); return x;}
std::vector< double > TMTQ::getTrise ( )

Definition at line 93 of file TMTQ.cc.

References iTrise, and x.

{std::vector<double> x=get(TMTQ::iTrise); return x;}
void TMTQ::init ( )

Definition at line 30 of file TMTQ.cc.

References hpstanc_transforms::cuts, and j.

{

  for(int j=0;j<nOutVar;j++){
    cuts[0][j]=0.0;
    cuts[1][j]=10.0e9;
    mom[j]=new TMom();
  }
}
void TMTQ::setCut ( int  ivar,
double  mean,
double  sig 
)

Definition at line 62 of file TMTQ.cc.

References hpstanc_transforms::cuts.

                                                  {

  if(ivar<nOutVar){
    cuts[0][ivar]=mean-2.0*sig;
    cuts[1][ivar]=mean+2.0*sig;
    
    mom[ivar]->setCut(cuts[0][ivar],cuts[1][ivar]);
  }
}

Member Data Documentation

double TMTQ::cuts[2][nOutVar]

Definition at line 16 of file TMTQ.h.

TMom* TMTQ::mom[nOutVar]

Definition at line 18 of file TMTQ.h.