REST-for-Physics  v2.3
Rare Event Searches ToolKit for Physics
Public Member Functions | Protected Attributes | Private Attributes
TRestDetectorHitsEvent Class Reference

Detailed Description

An event data type that register a std::vector of TRestHits, allowing us to save a 3-coordinate position and energy.

TRestDetectorHitsEvent is a structure that ...


RESTsoft - Software for Rare Event Searches with TPCs

History of developments:

2016-March: First implementation of hits event data type into REST_v2. Javier Galan

Author
Javier Galan

Definition at line 18 of file TRestDetectorHitsEvent.h.

#include <TRestDetectorHitsEvent.h>

Inheritance diagram for TRestDetectorHitsEvent:
TRestEvent

Public Member Functions

void AddHit (const TVector3 &position, Double_t energy, Double_t time, REST_HitType type=XYZ)
 Adds a new hit to this event. More...
 
void AddHit (Double_t x, Double_t y, Double_t z, Double_t en, Double_t t=0, REST_HitType type=XYZ)
 Adds a new hit to this event. More...
 
Bool_t allHitsInsideCylinder (TVector3 x0, TVector3 x1, Double_t radius)
 This method returns true if all hits are contained inside the cylinder volume given by argument. More...
 
Bool_t allHitsInsidePrism (TVector3 x0, TVector3 x1, Double_t sX, Double_t sY, Double_t theta)
 This method returns true if all hits are found inside the prism volume given by argument. More...
 
Bool_t anyHitInsideCylinder (TVector3 x0, TVector3 x1, Double_t radius)
 This method returns true if at least 1 hit is found inside the cylinder volume given by argument. More...
 
Bool_t anyHitInsidePrism (TVector3 x0, TVector3 x1, Double_t sizeX, Double_t sizeY, Double_t theta)
 This method returns true if at least 1 hit is found inside the prism volume given by argument. More...
 
TPad * DrawEvent (const TString &option="")
 This method draws the hits event structure into a TPad. More...
 
void DrawGraphs (Int_t &column)
 This method draw the hits events as a graph. More...
 
void DrawHistograms (Int_t &column, const TString &histOption="", double pitch=0)
 This method draw the hits events as an histogram. More...
 
Int_t GetClosestHit (const TVector3 &position) const
 
Double_t GetClosestHitInsideDistanceToCylinderBottom (TVector3 x0, TVector3 x1, Double_t radius)
 This method returns the distance to the cylinder bottom face from the closest hit contained inside the cylinder volume given by argument. More...
 
Double_t GetClosestHitInsideDistanceToCylinderTop (TVector3 x0, TVector3 x1, Double_t radius)
 This method returns the distance to the cylinder top face from the closest hit contained inside the cylinder volume given by argument. More...
 
Double_t GetClosestHitInsideDistanceToCylinderWall (TVector3 x0, TVector3 x1, Double_t radius)
 This method returns the distance to the cylinder wall from the closest hit contained inside the cylinder volume given by argument. More...
 
Double_t GetClosestHitInsideDistanceToPrismBottom (const TVector3 &x0, const TVector3 &x1, Double_t sizeX, Double_t sizeY, Double_t theta)
 This method returns the distance to the prism bottom face from the closest hit contained inside the prism volume given by argument. More...
 
Double_t GetClosestHitInsideDistanceToPrismTop (TVector3 x0, TVector3 x1, Double_t sizeX, Double_t sizeY, Double_t theta)
 This method returns the distance to the prism top face from the closest hit contained inside the prism volume given by argument. More...
 
Double_t GetClosestHitInsideDistanceToPrismWall (TVector3 x0, TVector3 x1, Double_t sizeX, Double_t sizeY, Double_t theta)
 This method returns the distance to the prism wall from the closest hit contained inside the prism volume given by argument. More...
 
Double_t GetDistance2 (int n, int m) const
 Returns the squared distance between hits n and m.
 
Double_t GetEnergy () const
 
Double_t GetEnergy (int n) const
 
Double_t GetEnergyInCylinder (TVector3 x0, TVector3 x1, Double_t radius)
 This method returns the total integrated energy of all hits found inside the cylinder volume given by argument. More...
 
Double_t GetEnergyInPrism (TVector3 x0, TVector3 x1, Double_t sizeX, Double_t sizeY, Double_t theta)
 This method returns the total integrated energy of all hits found inside the prism volume given by argument. More...
 
Double_t GetEnergyX () const
 
Double_t GetEnergyY () const
 
Double_t GetGaussSigmaX (Double_t error, Int_t nHitsMin)
 
Double_t GetGaussSigmaY (Double_t error, Int_t nHitsMin)
 
Double_t GetGaussSigmaZ (Double_t error, Int_t nHitsMin) const
 
TRestHitsGetHits () const
 
Double_t GetMaximumHitEnergy () const
 
Double_t GetMeanHitEnergy () const
 
TVector3 GetMeanPosition () const
 
TVector3 GetMeanPositionInCylinder (TVector3 x0, TVector3 x1, Double_t radius)
 This method returns the mean position of the hits found inside the cylinder volume given by argument. More...
 
TVector3 GetMeanPositionInPrism (TVector3 x0, TVector3 x1, Double_t sizeX, Double_t sizeY, Double_t theta)
 This method returns the mean position of all hits found inside the prism volume given by argument. More...
 
Double_t GetMeanPositionX () const
 
Double_t GetMeanPositionY () const
 
Double_t GetMeanPositionZ () const
 
Double_t GetMinimumHitEnergy () const
 
size_t GetNumberOfHits () const
 
Int_t GetNumberOfHitsInsideCylinder (TVector3 x0, TVector3 x1, Double_t radius)
 This method returns the total number hits found inside the cylinder volume given by argument. More...
 
Int_t GetNumberOfHitsInsidePrism (TVector3 x0, TVector3 x1, Double_t sizeX, Double_t sizeY, Double_t theta)
 This method returns the total number of hits found inside the prism volume given by argument. More...
 
Int_t GetNumberOfHitsX () const
 
Int_t GetNumberOfHitsY () const
 
TVector3 GetPosition (int n) const
 
Double_t GetSigmaX () const
 
Double_t GetSigmaXY2 () const
 
Double_t GetSigmaY () const
 
Double_t GetSigmaZ2 () const
 
Double_t GetSkewXY () const
 
Double_t GetSkewZ () const
 
Double_t GetTime (int n) const
 
Double_t GetTotalEnergy () const
 
REST_HitType GetType (int n) const
 
Double_t GetX (int n) const
 Returns the X-coordinate of hit entry n in mm.
 
TH2F * GetXYHistogram (std::vector< float > ranges, Double_t pitch=3, Double_t border=5)
 This method draws the hits found on XY as a TH2F and it returns the generated histogram. More...
 
TRestHitsGetXYZHits ()
 This method collects all hits which are compatible with a XYZ hit. More...
 
TH2F * GetXZHistogram (std::vector< float > ranges, Double_t pitch=3, Double_t border=5)
 This method draws the hits found on XY as a TH2F and it returns the generated histogram. More...
 
TRestHitsGetXZHits ()
 This method collects all hits which are compatible with a XZ-projected hit. More...
 
Double_t GetY (int n) const
 Returns the Y-coordinate of hit entry n in mm.
 
TH2F * GetYZHistogram (std::vector< float > ranges, Double_t pitch=3, Double_t border=5)
 This method draws the hits found on YZ as a TH2F and it returns the generated histogram. More...
 
TRestHitsGetYZHits ()
 This method collects all hits which are compatible with a YZ-projected hit. More...
 
Double_t GetZ (int n) const
 Returns the Z-coordinate of hit entry n in mm.
 
virtual void Initialize ()
 Removes all hits from this event, and clears all auxiliar variables.
 
virtual void PrintEvent () const
 
virtual void PrintEvent (Int_t nHits) const
 
void Shuffle (int NLoop)
 
void Sort (bool(compareCondition)(const TRestHits::iterator &hit1, const TRestHits::iterator &hit2)=nullptr)
 
 TRestDetectorHitsEvent ()
 TRestDetectorHitsEvent default constructor. More...
 
 ~TRestDetectorHitsEvent ()
 TRestDetectorHitsEvent default destructor.
 
- Public Member Functions inherited from TRestEvent
virtual void CloneTo (TRestEvent *target)
 Clone the content of this TRestEvent object to another. More...
 
Int_t GetID () const
 
Int_t GetRunOrigin () const
 
TString GetSubEventTag () const
 
Int_t GetSubID () const
 
Int_t GetSubRunOrigin () const
 
Double_t GetTime () const
 
TTimeStamp GetTimeStamp () const
 
virtual void InitializeReferences (TRestRun *run)
 Initialize dynamical references when loading the event from a root file. More...
 
virtual void InitializeWithMetadata (TRestRun *run)
 
Bool_t isOk () const
 
void SetEventInfo (TRestEvent *eve)
 
void SetID (Int_t id)
 
void SetOK (Bool_t state)
 
void SetRunOrigin (Int_t run_origin)
 
void SetState (Bool_t state)
 
void SetSubEventTag (const TString &tag)
 
void SetSubID (Int_t id)
 
void SetSubRunOrigin (Int_t sub_run_origin)
 
void SetTime (Double_t seconds, Double_t nanoseconds)
 
void SetTime (Double_t time)
 
void SetTimeStamp (const TTimeStamp &time)
 
 TRestEvent ()
 
virtual ~TRestEvent ()
 

Protected Attributes

TRestHitsfHits
 The hits structure that is is saved to disk.
 
TH1F * fXHisto
 An auxiliary TH1F histogram to visualize hits on X-projection.
 
TH2F * fXYHisto
 An auxiliary TH2F histogram to visualize hits on XY-projection.
 
TGraph * fXYHitGraph
 An auxiliary TGraph pointer to visualize hits on XY-projection.
 
TH2F * fXZHisto
 An auxiliary TH2F histogram to visualize hits on XZ-projection.
 
TGraph * fXZHitGraph
 An auxiliary TGraph pointer to visualize hits on XZ-projection.
 
TH1F * fYHisto
 An auxiliary TH1F histogram to visualize hits on Y-projection.
 
TH2F * fYZHisto
 An auxiliary TH2F histogram to visualize hits on YZ-projection.
 
TGraph * fYZHitGraph
 An auxiliary TGraph pointer to visualize hits on YZ-projection.
 
TH1F * fZHisto
 An auxiliary TH1F histogram to visualize hits on Z-projection.
 
- Protected Attributes inherited from TRestEvent
Int_t fEventID
 Event identification number.
 
TTimeStamp fEventTime
 Absolute event time.
 
Bool_t fOk
 Flag to be used by processes to define an event status. fOk=true is the default.
 
TPad * fPad
 
TRestRunfRun = nullptr
 
Int_t fRunOrigin
 Run ID number of the event.
 
Int_t fSubEventID
 Sub-Event identification number.
 
TString fSubEventTag
 A short length label to identify the sub-Event.
 
Int_t fSubRunOrigin
 Sub-run ID number of the event.
 

Private Attributes

TRestHitsfXYZHits
 An auxiliary TRestHits structure to register hits on XYZ projection.
 
TRestHitsfXZHits
 An auxiliary TRestHits structure to register hits on XZ projection.
 
TRestHitsfYZHits
 An auxiliary TRestHits structure to register hits on YZ projection.
 

Additional Inherited Members

- Protected Member Functions inherited from TRestEvent
void RestartPad (Int_t nElements)
 

Constructor & Destructor Documentation

◆ TRestDetectorHitsEvent()

TRestDetectorHitsEvent::TRestDetectorHitsEvent ( )

TRestDetectorHitsEvent default constructor.

If no configuration path is defined using TRestMetadata::SetConfigFilePath the path to the config file must be specified using full path, absolute or relative.

The default behaviour is that the config file must be specified with full path, absolute or relative.

Parameters
configFilenameA const char* giving the path to an RML file.

Definition at line 65 of file TRestDetectorHitsEvent.cxx.

Member Function Documentation

◆ AddHit() [1/2]

void TRestDetectorHitsEvent::AddHit ( const TVector3 &  position,
Double_t  energy,
Double_t  time,
REST_HitType  type = XYZ 
)

Adds a new hit to this event.

It adds a new hit with position pos in mm, and energy en in keV, to this TRestDetectorHitsEvent structure. Additionally a time delay value in us may be added to the hits.

Definition at line 108 of file TRestDetectorHitsEvent.cxx.

◆ AddHit() [2/2]

void TRestDetectorHitsEvent::AddHit ( Double_t  x,
Double_t  y,
Double_t  z,
Double_t  en,
Double_t  t = 0,
REST_HitType  type = XYZ 
)

Adds a new hit to this event.

It adds a new hit with coordinates x,y,z in mm, and energy en in keV, to this TRestDetectorHitsEvent structure. Additionally a time delay value in us may be added to the hits.

Definition at line 98 of file TRestDetectorHitsEvent.cxx.

◆ allHitsInsideCylinder()

Bool_t TRestDetectorHitsEvent::allHitsInsideCylinder ( TVector3  x0,
TVector3  x1,
Double_t  radius 
)

This method returns true if all hits are contained inside the cylinder volume given by argument.

Parameters
x0The center of the bottom face of the cylinder.
x1The center of the top face of the cylinder.
radiusThe radius of the cylinder.

Definition at line 247 of file TRestDetectorHitsEvent.cxx.

◆ allHitsInsidePrism()

Bool_t TRestDetectorHitsEvent::allHitsInsidePrism ( TVector3  x0,
TVector3  x1,
Double_t  sizeX,
Double_t  sizeY,
Double_t  theta 
)

This method returns true if all hits are found inside the prism volume given by argument.

Parameters
x0The center of the bottom face of the prism.
x1The center of the top face of the prism.
sizeXSize of the side X of the prism face.
sizeYSize of the side X of the prism face.
thetaAn angle in radians to rotate the face of the prism.

Definition at line 314 of file TRestDetectorHitsEvent.cxx.

◆ anyHitInsideCylinder()

Bool_t TRestDetectorHitsEvent::anyHitInsideCylinder ( TVector3  x0,
TVector3  x1,
Double_t  radius 
)

This method returns true if at least 1 hit is found inside the cylinder volume given by argument.

Parameters
x0The center of the bottom face of the cylinder.
x1The center of the top face of the cylinder.
radiusThe radius of the cylinder.

Definition at line 232 of file TRestDetectorHitsEvent.cxx.

◆ anyHitInsidePrism()

Bool_t TRestDetectorHitsEvent::anyHitInsidePrism ( TVector3  x0,
TVector3  x1,
Double_t  sizeX,
Double_t  sizeY,
Double_t  theta 
)

This method returns true if at least 1 hit is found inside the prism volume given by argument.

Parameters
x0The center of the bottom face of the prism.
x1The center of the top face of the prism.
sizeXSize of the side X of the prism face.
sizeYSize of the side X of the prism face.
thetaAn angle in radians to rotate the face of the prism.

Definition at line 298 of file TRestDetectorHitsEvent.cxx.

◆ DrawEvent()

TPad * TRestDetectorHitsEvent::DrawEvent ( const TString &  option = "")
virtual

This method draws the hits event structure into a TPad.

This method receives as argument a string that defines the different plots to be produced.

The following options are allowed:

  1. graph: It draws the hits using a TGraph drawing method.
  2. hist: It generates histograms in XY, XZ and YZ projections using the projected event hits at the corresponding plane, the bins are weighted with their corresponding energy. Histograms will accept as argument, between parenthesis, a conventional ROOT option, i.e. hist(rootOption), where rootOption is any valid ROOT option as described by the THistPainter ROOT class. The default binning size is defined to be automatic, but the user is able to define a custom bin size of the histogram using the [ ]. i.e. the following example will define the bin size to 1mm. Example: hist(Cont0,colz)[1].

3 print: It will print on screen the result of TRestDetectorHitsEvent::PrintEvent.

The different options must separated by colons, as "option1:option2:option3".

Returns
A pointer to the TPad where the event was drawn is returned.

The default histogram using a pitch of 0 mm,

Reimplemented from TRestEvent.

Definition at line 611 of file TRestDetectorHitsEvent.cxx.

◆ DrawGraphs()

void TRestDetectorHitsEvent::DrawGraphs ( Int_t &  column)

This method draw the hits events as a graph.

This method receives as argument the column to be drawn in the TPad.

The different TGraphs are drawn in a TPad *fPad defined as global variable

Definition at line 682 of file TRestDetectorHitsEvent.cxx.

◆ DrawHistograms()

void TRestDetectorHitsEvent::DrawHistograms ( Int_t &  column,
const TString &  histOption = "",
double  pitch = 0 
)

This method draw the hits events as an histogram.

This method receives the following arguments: -The column to be drawn in the TPad. -The histOption used as Draw option for the histograms -The pitch size which defines the number of bins of the histograms, if the pitch size is zero, the bins are drawn based on the minDiff of a particular axis. Otherwise, the pitch passed as argument is used to define the bin size, the histogram boundaries are based on the max/min values of a particular axis.

The different histograms are drawn in a TPad *fPad defined as global variable

Definition at line 793 of file TRestDetectorHitsEvent.cxx.

◆ GetClosestHitInsideDistanceToCylinderBottom()

Double_t TRestDetectorHitsEvent::GetClosestHitInsideDistanceToCylinderBottom ( TVector3  x0,
TVector3  x1,
Double_t  radius 
)

This method returns the distance to the cylinder bottom face from the closest hit contained inside the cylinder volume given by argument.

Parameters
x0The center of the bottom face of the cylinder.
x1The center of the top face of the cylinder.
radiusThe radius of the cylinder.
Returns
If no hit is found inside the cylinder, -1 is returned.

Definition at line 449 of file TRestDetectorHitsEvent.cxx.

◆ GetClosestHitInsideDistanceToCylinderTop()

Double_t TRestDetectorHitsEvent::GetClosestHitInsideDistanceToCylinderTop ( TVector3  x0,
TVector3  x1,
Double_t  radius 
)

This method returns the distance to the cylinder top face from the closest hit contained inside the cylinder volume given by argument.

Parameters
x0The center of the bottom face of the cylinder.
x1The center of the top face of the cylinder.
radiusThe radius of the cylinder.
Returns
If no hit is found inside the cylinder, -1 is returned.

Definition at line 415 of file TRestDetectorHitsEvent.cxx.

◆ GetClosestHitInsideDistanceToCylinderWall()

Double_t TRestDetectorHitsEvent::GetClosestHitInsideDistanceToCylinderWall ( TVector3  x0,
TVector3  x1,
Double_t  radius 
)

This method returns the distance to the cylinder wall from the closest hit contained inside the cylinder volume given by argument.

Parameters
x0The center of the bottom face of the cylinder.
x1The center of the top face of the cylinder.
radiusThe radius of the cylinder.
Returns
If no hit is found inside the cylinder, -1 is returned.

Definition at line 377 of file TRestDetectorHitsEvent.cxx.

◆ GetClosestHitInsideDistanceToPrismBottom()

Double_t TRestDetectorHitsEvent::GetClosestHitInsideDistanceToPrismBottom ( const TVector3 &  x0,
const TVector3 &  x1,
Double_t  sizeX,
Double_t  sizeY,
Double_t  theta 
)

This method returns the distance to the prism bottom face from the closest hit contained inside the prism volume given by argument.

Parameters
x0The center of the bottom face of the prism.
x1The center of the top face of the prism.
sizeXSize of the side X of the prism face.
sizeYSize of the side X of the prism face.
thetaAn angle in radians to rotate the face of the prism.
Returns
If no hit is found inside the prism, -1 is returned.

Definition at line 562 of file TRestDetectorHitsEvent.cxx.

◆ GetClosestHitInsideDistanceToPrismTop()

Double_t TRestDetectorHitsEvent::GetClosestHitInsideDistanceToPrismTop ( TVector3  x0,
TVector3  x1,
Double_t  sizeX,
Double_t  sizeY,
Double_t  theta 
)

This method returns the distance to the prism top face from the closest hit contained inside the prism volume given by argument.

Parameters
x0The center of the bottom face of the prism.
x1The center of the top face of the prism.
sizeXSize of the side X of the prism face.
sizeYSize of the side X of the prism face.
thetaAn angle in radians to rotate the face of the prism.
Returns
If no hit is found inside the prism, -1 is returned.

Definition at line 525 of file TRestDetectorHitsEvent.cxx.

◆ GetClosestHitInsideDistanceToPrismWall()

Double_t TRestDetectorHitsEvent::GetClosestHitInsideDistanceToPrismWall ( TVector3  x0,
TVector3  x1,
Double_t  sizeX,
Double_t  sizeY,
Double_t  theta 
)

This method returns the distance to the prism wall from the closest hit contained inside the prism volume given by argument.

Parameters
x0The center of the bottom face of the prism.
x1The center of the top face of the prism.
sizeXSize of the side X of the prism face.
sizeYSize of the side X of the prism face.
thetaAn angle in radians to rotate the face of the prism.
Returns
If no hit is found inside the prism, -1 is returned.

Definition at line 485 of file TRestDetectorHitsEvent.cxx.

◆ GetEnergyInCylinder()

Double_t TRestDetectorHitsEvent::GetEnergyInCylinder ( TVector3  x0,
TVector3  x1,
Double_t  radius 
)

This method returns the total integrated energy of all hits found inside the cylinder volume given by argument.

Parameters
x0The center of the bottom face of the cylinder.
x1The center of the top face of the cylinder.
radiusThe radius of the cylinder.

Definition at line 261 of file TRestDetectorHitsEvent.cxx.

◆ GetEnergyInPrism()

Double_t TRestDetectorHitsEvent::GetEnergyInPrism ( TVector3  x0,
TVector3  x1,
Double_t  sizeX,
Double_t  sizeY,
Double_t  theta 
)

This method returns the total integrated energy of all hits found inside the prism volume given by argument.

Parameters
x0The center of the bottom face of the prism.
x1The center of the top face of the prism.
sizeXSize of the side X of the prism face.
sizeYSize of the side X of the prism face.
thetaAn angle in radians to rotate the face of the prism.

Definition at line 332 of file TRestDetectorHitsEvent.cxx.

◆ GetMeanPositionInCylinder()

TVector3 TRestDetectorHitsEvent::GetMeanPositionInCylinder ( TVector3  x0,
TVector3  x1,
Double_t  radius 
)

This method returns the mean position of the hits found inside the cylinder volume given by argument.

Parameters
x0The center of the bottom face of the cylinder.
x1The center of the top face of the cylinder.
radiusThe radius of the cylinder.

Definition at line 285 of file TRestDetectorHitsEvent.cxx.

◆ GetMeanPositionInPrism()

TVector3 TRestDetectorHitsEvent::GetMeanPositionInPrism ( TVector3  x0,
TVector3  x1,
Double_t  sizeX,
Double_t  sizeY,
Double_t  theta 
)

This method returns the mean position of all hits found inside the prism volume given by argument.

Parameters
x0The center of the bottom face of the prism.
x1The center of the top face of the prism.
sizeXSize of the side X of the prism face.
sizeYSize of the side X of the prism face.
thetaAn angle in radians to rotate the face of the prism.

Definition at line 362 of file TRestDetectorHitsEvent.cxx.

◆ GetNumberOfHitsInsideCylinder()

Int_t TRestDetectorHitsEvent::GetNumberOfHitsInsideCylinder ( TVector3  x0,
TVector3  x1,
Double_t  radius 
)

This method returns the total number hits found inside the cylinder volume given by argument.

Parameters
x0The center of the bottom face of the cylinder.
x1The center of the top face of the cylinder.
radiusThe radius of the cylinder.

Definition at line 273 of file TRestDetectorHitsEvent.cxx.

◆ GetNumberOfHitsInsidePrism()

Int_t TRestDetectorHitsEvent::GetNumberOfHitsInsidePrism ( TVector3  x0,
TVector3  x1,
Double_t  sizeX,
Double_t  sizeY,
Double_t  theta 
)

This method returns the total number of hits found inside the prism volume given by argument.

Parameters
x0The center of the bottom face of the prism.
x1The center of the top face of the prism.
sizeXSize of the side X of the prism face.
sizeYSize of the side X of the prism face.
thetaAn angle in radians to rotate the face of the prism.

Definition at line 347 of file TRestDetectorHitsEvent.cxx.

◆ GetXYHistogram()

TH2F * TRestDetectorHitsEvent::GetXYHistogram ( std::vector< float >  ranges,
Double_t  pitch = 3,
Double_t  border = 5 
)

This method draws the hits found on XY as a TH2F and it returns the generated histogram.

The first argument allows to define the ranges in the format: {binsX, minX, maxX, binsY, minY, maxY}.

The pitch allows to adjust the binning in automatic mode (when ranges vector is empty).

The border gives an additional margin to the automatic minX, maxX, minY, maxY found.

Definition at line 984 of file TRestDetectorHitsEvent.cxx.

◆ GetXYZHits()

TRestHits * TRestDetectorHitsEvent::GetXYZHits ( )

This method collects all hits which are compatible with a XYZ hit.

A XYZ hit compatible are those hits that have valid X, Y and Z coordinates.

Returns
It returns back a TRestHits structure with the hits fulfilling the XYZ condition.

Definition at line 210 of file TRestDetectorHitsEvent.cxx.

◆ GetXZHistogram()

TH2F * TRestDetectorHitsEvent::GetXZHistogram ( std::vector< float >  ranges,
Double_t  pitch = 3,
Double_t  border = 5 
)

This method draws the hits found on XY as a TH2F and it returns the generated histogram.

The first argument allows to define the ranges in the format: {binsX, minX, maxX, binsZ, minZ, maxZ}.

The pitch allows to adjust the binning in automatic mode (when ranges vector is empty).

The border gives an additional margin to the automatic minX, maxX, minZ, maxZ found.

Definition at line 1071 of file TRestDetectorHitsEvent.cxx.

◆ GetXZHits()

TRestHits * TRestDetectorHitsEvent::GetXZHits ( )

This method collects all hits which are compatible with a XZ-projected hit.

A hit compatible with XZ projection are those hits that have undetermined Y coordinate, and valid X and Z coordinates.

Returns
It returns back a TRestHits structure with the hits fulfilling the XZ condition.

Definition at line 170 of file TRestDetectorHitsEvent.cxx.

◆ GetYZHistogram()

TH2F * TRestDetectorHitsEvent::GetYZHistogram ( std::vector< float >  ranges,
Double_t  pitch = 3,
Double_t  border = 5 
)

This method draws the hits found on YZ as a TH2F and it returns the generated histogram.

The first argument allows to define the ranges in the format: {binsY, minY, maxY, binsZ, minZ, maxZ}.

The pitch allows to adjust the binning in automatic mode (when ranges vector is empty).

The border gives an additional margin to the automatic minY, maxY, minZ, maxZ found.

Definition at line 1158 of file TRestDetectorHitsEvent.cxx.

◆ GetYZHits()

TRestHits * TRestDetectorHitsEvent::GetYZHits ( )

This method collects all hits which are compatible with a YZ-projected hit.

A hit compatible with XZ projection are those hits that have undetermined X coordinate, and valid Y and Z coordinates.

Returns
It returns back a TRestHits structure with the hits fulfilling the XZ condition.

Definition at line 190 of file TRestDetectorHitsEvent.cxx.

◆ PrintEvent()

virtual void TRestDetectorHitsEvent::PrintEvent ( ) const
inlinevirtual

Run to print event data info on console To be re-implemented in derived class. You may want to call the base class inside the re-implemented one, by calling TRestEvent::PrintEvent();

Reimplemented from TRestEvent.

Definition at line 88 of file TRestDetectorHitsEvent.h.


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