Heavy ion Analysis Libriares
Loading...
Searching...
No Matches
Hal::Cut Class Reference

#include <Cut.h>

Inheritance diagram for Hal::Cut:
Hal::EventCut Hal::TrackCut Hal::TwoTrackCut Hal::EventBinningCut Hal::EventComplexCut Hal::EventExpCut Hal::EventImaginaryCut Hal::EventMcCut Hal::EventModuloCut Hal::EventMultiChargedCut Hal::EventMultiplicityCut Hal::EventMultiplicityZVertexCut Hal::EventPhiCut Hal::EventPrimaryTracksNoCut Hal::EventPtMaxCut Hal::EventRealCut Hal::EventVertexCut Hal::EventVertexXYZCut Hal::EventVertexZCut Hal::EventVirtualCut MyHal::EventCutTemplate Hal::TrackBetaCut Hal::TrackBoostedDeltaPCut Hal::TrackBoostedKinematcisCut Hal::TrackBoostedPCut Hal::TrackChargeCut Hal::TrackComplexCut Hal::TrackDCACut Hal::TrackDeltaMomentumCut Hal::TrackEtaAbsCut Hal::TrackEtaCut Hal::TrackExpCut Hal::TrackGlobalFlagCut Hal::TrackGoodSecondaryFlagCut Hal::TrackImaginaryCut Hal::TrackMCCut Hal::TrackMassCut Hal::TrackMtCut Hal::TrackNullCut Hal::TrackOnlyPrimariesCut Hal::TrackPCut Hal::TrackPSignedCut Hal::TrackPdgBinCut Hal::TrackPhiCut Hal::TrackPrimaryFlagCut Hal::TrackPtCut Hal::TrackPzCut Hal::TrackRandomCut Hal::TrackRealCut Hal::TrackStatusCut Hal::TrackThetaCut Hal::TrackV0Cut Hal::TrackV0FlagCut Hal::TrackVirtualCut Hal::TrackYAssumedCut Hal::TrackYCut MyHal::TrackCutTemplate Hal::PairDeltaQinvCut Hal::PairEtaPtCut Hal::PdgBinPairCut Hal::SameMotherMcCut Hal::TwoTrack3DCFCut Hal::TwoTrackAntiSplittingCut Hal::TwoTrackComplexCut Hal::TwoTrackDCACut Hal::TwoTrackDebugCut Hal::TwoTrackDeltaEtaCut Hal::TwoTrackDphiDetaCut Hal::TwoTrackDphistarDetaCut Hal::TwoTrackEtaCut Hal::TwoTrackFemtoPRFCut Hal::TwoTrackFemtoQinvCut Hal::TwoTrackImaginaryCut Hal::TwoTrackKtCut Hal::TwoTrackLCMSCut Hal::TwoTrackMinvCut Hal::TwoTrackPhiCut Hal::TwoTrackPtOrderCut Hal::TwoTrackPtSumCut Hal::TwoTrackRadialDistanceCut Hal::TwoTrackRapidityCut Hal::TwoTrackRealCut Hal::TwoTrackSailorCowboyCut Hal::TwoTrackVirtualCut Hal::V0CandBasicCut MyHal::TwoTrackCutTemplate

Public Member Functions

 Cut (const Int_t size=1, ECutUpdate update=ECutUpdate::kNo, TString groupFlag="")
 
 Cut (const Cut &cut)
 
Cutoperator= (const Cut &other)
 
void SetLabel (Int_t label)
 
void Finish ()
 
void Reset ()
 
void SetMinAndMax (Double_t val, Int_t i=0)
 
void SetMinMax (Double_t min, Double_t max, Int_t i=0)
 
TString GetGroupFlag () const
 
ECutUpdate GetUpdateRatio () const
 
Cut ** MultiClone (Int_t no, Bool_t increment_collections=kFALSE)
 
void SetMinimum (Double_t min, Int_t i=0)
 
void SetMaximum (Double_t max, Int_t i=0)
 
void SetValue (Double_t val, Int_t i=0)
 
void SetUnitName (TString name, Int_t i=0)
 
void SetCollectionID (Int_t i)
 
Int_t GetCutSize () const
 
Int_t GetCollectionID () const
 
Bool_t HasPassed () const
 
Bool_t IsCloned () const
 
Double_t GetMin (Int_t i=0) const
 
Double_t GetMax (Int_t i=0) const
 
Double_t GetValue (Int_t i=0) const
 
Double_t GetWeight ()
 
ULong64_t GetPassed () const
 
ULong64_t GetTotal () const
 
ULong64_t GetFailed () const
 
TString GetUnit (Int_t i) const
 
virtual CutMakeCopy () const
 
virtual PackageReport () const
 
virtual void Print (Option_t *option="") const
 
TObjArray * Split (Int_t n, Int_t i=0, Double_t shift=0) const
 
virtual Bool_t Init (Int_t=0)
 
virtual TString CutName (Option_t *opt="") const
 
virtual std::vector< std::pair< TString, Double_t > > GetBinLabels (Int_t par=0) const
 

Protected Member Functions

Bool_t Validate ()
 
Bool_t AntiValidate ()
 
Bool_t ValidateAbs ()
 
Bool_t ForcedUpdate (Bool_t state)
 
Bool_t FormatEquals (TString format, Int_t format_id, EFormatDepth depth=EFormatDepth::kAll) const
 
Bool_t FormatInhertis (TString format, Int_t format_id, EFormatDepth depth=EFormatDepth::kAll) const
 
Bool_t InLimits (Int_t par) const
 
Bool_t OutLimits (Int_t par) const
 

Protected Attributes

const Int_t fCutSize
 
Bool_t fInit
 
Int_t fIsCloned
 
Int_t fState
 
Int_t fCollectionID
 
Int_t fLabel
 
const ECutUpdate fUpdateRatio
 
Double_t fWeight
 
const TString fGroupFlag
 

Friends

class EventComplexCut
 
class EventImaginaryCut
 
class EventRealCut
 
class TrackComplexCut
 
class TrackImaginaryCut
 
class TrackRealCut
 
class TwoTrackComplexCut
 
class TwoTrackImaginaryCut
 
class TwoTrackRealCut
 

Detailed Description

basic abstract class for all cuts

Definition at line 40 of file Cut.h.

Constructor & Destructor Documentation

◆ Cut() [1/2]

Hal::Cut::Cut ( const Int_t size = 1,
ECutUpdate update = ECutUpdate::kNo,
TString groupFlag = "" )

default constructor

Parameters
size- number of values in cut

Definition at line 12 of file Cut.cxx.

◆ Cut() [2/2]

Hal::Cut::Cut ( const Cut & cut)

copy constructor

Parameters
cut

Definition at line 28 of file Cut.cxx.

◆ ~Cut()

virtual Hal::Cut::~Cut ( )
inlinevirtual

Definition at line 364 of file Cut.h.

Member Function Documentation

◆ AntiValidate()

Bool_t Hal::Cut::AntiValidate ( )
protected

similar to validate but instead passing obj that is between min and max, pass object that is not between those two values

Returns
true if objcet passed

Definition at line 55 of file Cut.cxx.

◆ CutName()

TString Hal::Cut::CutName ( Option_t * opt = "") const
virtual
Parameters
optadditional option, if you add this cut directly then not used, however if you create pure real /imaginary cut then you can get obtain complex cut name by set option "re" or "im"
Returns
name of cut (usally Classname)

Reimplemented in Hal::EventBinningCut, Hal::EventComplexCut, Hal::EventImaginaryCut, Hal::EventRealCut, Hal::TrackComplexCut, Hal::TrackImaginaryCut, Hal::TrackRealCut, Hal::TwoTrackComplexCut, Hal::TwoTrackImaginaryCut, and Hal::TwoTrackRealCut.

Definition at line 214 of file Cut.cxx.

◆ Finish()

void Hal::Cut::Finish ( )
inline

not used

Definition at line 182 of file Cut.h.

◆ ForcedUpdate()

Bool_t Hal::Cut::ForcedUpdate ( Bool_t state)
protected

update value of cut without validating

Parameters
statenew state (true if object is ok, false otherwise)
Returns
state value

Definition at line 79 of file Cut.cxx.

◆ FormatEquals()

Bool_t Hal::Cut::FormatEquals ( TString format,
Int_t format_id,
EFormatDepth depth = EFormatDepth::kAll ) const
protected

check if this used format is supported by this cut

Parameters
formatrequired format
format_idformat id (from Init())
Returns
true if format with given format_id is the same as required

Definition at line 187 of file Cut.cxx.

◆ FormatInhertis()

Bool_t Hal::Cut::FormatInhertis ( TString format,
Int_t format_id,
EFormatDepth depth = EFormatDepth::kAll ) const
protected

check if this used format is supported by this cut

Parameters
formatrequired format
format_idformat id (from Init())
Returns
true if format with given format_id inherints from "format"

Definition at line 202 of file Cut.cxx.

◆ GetBinLabels()

std::vector< std::pair< TString, Double_t > > Hal::Cut::GetBinLabels ( Int_t par = 0) const
virtual

optional function used to set names of bin in non-standard histograms, labels are set to report histogram.

See also
PdgBinPairCut as an example
Parameters
paremeternumber
Returns
vector of names used in cut histogram first parameter is name of bin, second is value of bin center

Reimplemented in Hal::PdgBinPairCut.

Definition at line 246 of file Cut.cxx.

◆ GetCollectionID()

Int_t Hal::Cut::GetCollectionID ( ) const
inline
Returns
collection number

Definition at line 257 of file Cut.h.

◆ GetCutSize()

Int_t Hal::Cut::GetCutSize ( ) const
inline
Returns
number of checked parameters

Definition at line 252 of file Cut.h.

◆ GetFailed()

ULong64_t Hal::Cut::GetFailed ( ) const
inline
Returns
number of objects that didn't pass thought this cut

Definition at line 305 of file Cut.h.

◆ GetGroupFlag()

TString Hal::Cut::GetGroupFlag ( ) const
inline
Returns
flag group

Definition at line 204 of file Cut.h.

◆ GetMax()

Double_t Hal::Cut::GetMax ( Int_t i = 0) const
inline
Parameters
iparameter number
Returns
maximum value of parameter

Definition at line 279 of file Cut.h.

◆ GetMin()

Double_t Hal::Cut::GetMin ( Int_t i = 0) const
inline
Parameters
iparameter number
Returns
mimal value of parameter

Definition at line 273 of file Cut.h.

◆ GetPassed()

ULong64_t Hal::Cut::GetPassed ( ) const
inline
Returns
number of objects that pass thought this cut

Definition at line 295 of file Cut.h.

◆ GetTotal()

ULong64_t Hal::Cut::GetTotal ( ) const
inline
Returns
total number of checked objects

Definition at line 300 of file Cut.h.

◆ GetUnit()

TString Hal::Cut::GetUnit ( Int_t i) const
inline
Parameters
iparameter no
Returns
unit name

Definition at line 311 of file Cut.h.

◆ GetUpdateRatio()

ECutUpdate Hal::Cut::GetUpdateRatio ( ) const
inline
Returns
update ratio

Definition at line 209 of file Cut.h.

◆ GetValue()

Double_t Hal::Cut::GetValue ( Int_t i = 0) const
inline
Parameters
iparameter value
Returns
last checked value of parameter

Definition at line 285 of file Cut.h.

◆ GetWeight()

Double_t Hal::Cut::GetWeight ( )
inline
Returns
weight of checked object (not used)

Definition at line 290 of file Cut.h.

◆ HasPassed()

Bool_t Hal::Cut::HasPassed ( ) const
inline
Returns
true if last object pass throught this cut, false otherwise

Definition at line 262 of file Cut.h.

◆ Init()

◆ InLimits()

Bool_t Hal::Cut::InLimits ( Int_t par) const
protected
Parameters
parparameter number
Returns
true if parameter valu is in limits

Definition at line 240 of file Cut.cxx.

◆ IsCloned()

Bool_t Hal::Cut::IsCloned ( ) const
inline
Returns
true if this cut is cloned (not used)

Definition at line 267 of file Cut.h.

◆ MakeCopy()

virtual Cut * Hal::Cut::MakeCopy ( ) const
inlinevirtual

copy of this cut, can be implemented by CutDef macro (if cut don't have dynamically allocated objects or have copy ctor

Returns
copy of this cut

Reimplemented in Hal::EventBinningCut, and Hal::TwoTrack3DCFCut.

Definition at line 317 of file Cut.h.

◆ MultiClone()

Cut ** Hal::Cut::MultiClone ( Int_t no,
Bool_t increment_collections = kFALSE )

return copies of this cut

Parameters
nonumber of copies
increment_collectionsif true then collection number are incremented by 1
Returns
array of clones

Definition at line 102 of file Cut.cxx.

◆ operator=()

Cut & Hal::Cut::operator= ( const Cut & other)

default assignement operator

Parameters
other
Returns

Definition at line 170 of file Cut.cxx.

◆ OutLimits()

Bool_t Hal::Cut::OutLimits ( Int_t par) const
inlineprotected
Parameters
parparameter number
Returns
true if prameter is outside limits

Definition at line 155 of file Cut.h.

◆ Print()

void Hal::Cut::Print ( Option_t * option = "") const
virtual

print information about this cut

Reimplemented in Hal::EventBinningCut, and Hal::EventRunCut.

Definition at line 159 of file Cut.cxx.

◆ Report()

◆ Reset()

void Hal::Cut::Reset ( )

reset counters

Definition at line 41 of file Cut.cxx.

◆ SetCollectionID()

void Hal::Cut::SetCollectionID ( Int_t i)
inline

set collection number for this cut, collection number define in witch cut collection this cut will be stored

Parameters
icollection number

Definition at line 247 of file Cut.h.

◆ SetLabel()

void Hal::Cut::SetLabel ( Int_t label)
inline

set label for this cut, labels are used to distninguish between cuts with the same name that should be used in the same analysis

Parameters
label

Definition at line 178 of file Cut.h.

◆ SetMaximum()

void Hal::Cut::SetMaximum ( Double_t max,
Int_t i = 0 )
inline

set maximal value of cut for given parameter

Parameters
maxmaimum value
iparameter number

Definition at line 229 of file Cut.h.

◆ SetMinAndMax()

void Hal::Cut::SetMinAndMax ( Double_t val,
Int_t i = 0 )
See also
SetMinMax, call SetMinMax(val,val)
Parameters
valvalue of cut
iparameter number

Definition at line 91 of file Cut.cxx.

◆ SetMinimum()

void Hal::Cut::SetMinimum ( Double_t min,
Int_t i = 0 )
inline

set mimal value of cut for given parameter

Parameters
minmimimal value
iparameter number

Definition at line 223 of file Cut.h.

◆ SetMinMax()

void Hal::Cut::SetMinMax ( Double_t min,
Double_t max,
Int_t i = 0 )

set mim and maximum values of parameters

Parameters
minminimum value of paramter
maxmaximum value of parameter
iparameter number

Definition at line 93 of file Cut.cxx.

◆ SetUnitName()

void Hal::Cut::SetUnitName ( TString name,
Int_t i = 0 )
inline

set unit name

Parameters
nameunit name
iparameter no

Definition at line 241 of file Cut.h.

◆ SetValue()

void Hal::Cut::SetValue ( Double_t val,
Int_t i = 0 )
inline

set value of parameter (later used for veryficatio

Parameters
valvalue of parameter
iparameter number

Definition at line 235 of file Cut.h.

◆ Split()

TObjArray * Hal::Cut::Split ( Int_t n,
Int_t i = 0,
Double_t shift = 0 ) const

create many cuts with acceptations of this_cut/n. For example if we have "AB" cut with A:<-10;10> and B<0;5> AB->Split(2,0) create two cuts: (A<-10;0> B<0;5>) and (A<0;10> B<0;5>) whereas AB->Split(2,1) creates (A<-10;10> B<0,2.5>) and (A<-10;10> B<2.5;5>);

Parameters
nnumber of cuts
iparamter of cut that will be used for splitiing
shiftshift parameter - used if you want to avoid "overlapping of cuts. This shifts boundary of cuts. If shift is positive then lower boundary is increased, if shift is negative then upper boundary is decreased. For example if cuts is <0,10> Split(2,0,-1) makes cuts <0.4> <5,10>) Split(2,0,0.5) makes <0,5> <5.5,10>
Returns

Definition at line 131 of file Cut.cxx.

◆ Validate()

Bool_t Hal::Cut::Validate ( )
protected
Returns
true if objcet passed

Definition at line 43 of file Cut.cxx.

◆ ValidateAbs()

Bool_t Hal::Cut::ValidateAbs ( )
protected
Returns
true if abs values passed

Definition at line 67 of file Cut.cxx.

Friends And Related Symbol Documentation

◆ EventComplexCut

friend class EventComplexCut
friend

Definition at line 41 of file Cut.h.

◆ EventImaginaryCut

friend class EventImaginaryCut
friend

Definition at line 42 of file Cut.h.

◆ EventRealCut

friend class EventRealCut
friend

Definition at line 43 of file Cut.h.

◆ TrackComplexCut

friend class TrackComplexCut
friend

Definition at line 45 of file Cut.h.

◆ TrackImaginaryCut

friend class TrackImaginaryCut
friend

Definition at line 46 of file Cut.h.

◆ TrackRealCut

friend class TrackRealCut
friend

Definition at line 47 of file Cut.h.

◆ TwoTrackComplexCut

friend class TwoTrackComplexCut
friend

Definition at line 49 of file Cut.h.

◆ TwoTrackImaginaryCut

friend class TwoTrackImaginaryCut
friend

Definition at line 50 of file Cut.h.

◆ TwoTrackRealCut

friend class TwoTrackRealCut
friend

Definition at line 51 of file Cut.h.

Member Data Documentation

◆ fCollectionID

Int_t Hal::Cut::fCollectionID
protected

collection number of this cut

Definition at line 91 of file Cut.h.

◆ fCutSize

const Int_t Hal::Cut::fCutSize
protected

number of parameter checked by cut

Definition at line 75 of file Cut.h.

◆ fGroupFlag

const TString Hal::Cut::fGroupFlag
protected

group of cut (used for description of axes)

Definition at line 107 of file Cut.h.

◆ fInit

Bool_t Hal::Cut::fInit
protected

return true if cut has been initialized

Definition at line 79 of file Cut.h.

◆ fIsCloned

Int_t Hal::Cut::fIsCloned
protected

not used

Definition at line 83 of file Cut.h.

◆ fLabel

Int_t Hal::Cut::fLabel
protected

label to distinguish between cuts with the same name

Definition at line 95 of file Cut.h.

◆ fState

Int_t Hal::Cut::fState
protected

state of this cut 0 -if object didn't pass, 1 if passed

Definition at line 87 of file Cut.h.

◆ fUpdateRatio

const ECutUpdate Hal::Cut::fUpdateRatio
protected

ration of uddating this cut

Definition at line 99 of file Cut.h.

◆ fWeight

Double_t Hal::Cut::fWeight
protected

weight of cut (not used)

Definition at line 103 of file Cut.h.


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