ATTPCROOT  0.3.0-alpha
A ROOT-based framework for analyzing data from active target detectors
AtWeightedGaussian.h
Go to the documentation of this file.
1 #ifndef ATWEIGHTEDGAUSSIAN_H
2 #define ATWEIGHTEDGAUSSIAN_H
3 
4 #include "AtChargeWeighted.h"
5 #include "AtHit.h" // for AtHit
7 
8 #include <vector> // for vector
9 
10 namespace RandomSample {
11 
21 protected:
22  double fSigma; //< Sigma of gaussian around fReferencehit to sample [mm]
24 
25 public:
26  AtWeightedGaussian(double sigma = 30) : fSigma(sigma) {}
27  virtual void SetHitsToSample(const std::vector<const AtHit *> &hits) override;
28 
29 protected:
30  virtual std::vector<double> PDF(const AtHit &hit) override;
31  virtual void SampleReferenceHit() override;
32 };
33 } // namespace RandomSample
34 #endif // ATSAMPLEGAUSSIAN_H
AtSampleFromReference.h
RandomSample::AtWeightedGaussian
Sample with a charge-weighted gaussian.
Definition: AtWeightedGaussian.h:20
RandomSample
Definition: AtSampleConsensus.h:26
RandomSample::AtWeightedGaussian::SetHitsToSample
virtual void SetHitsToSample(const std::vector< const AtHit * > &hits) override
Definition: AtWeightedGaussian.cxx:14
AtChargeWeighted.h
RandomSample::AtWeightedGaussian::AtWeightedGaussian
AtWeightedGaussian(double sigma=30)
Definition: AtWeightedGaussian.h:26
AtHit.h
RandomSample::AtWeightedGaussian::fSigma
double fSigma
Definition: AtWeightedGaussian.h:22
RandomSample::AtSampleFromReference
Sample when PDF depends on reference.
Definition: AtSampleFromReference.h:18
RandomSample::AtChargeWeighted
Sample AtHits according to charge.
Definition: AtChargeWeighted.h:17
RandomSample::AtWeightedGaussian::SampleReferenceHit
virtual void SampleReferenceHit() override
Get reference hit from fHits.
Definition: AtWeightedGaussian.cxx:27
RandomSample::AtWeightedGaussian::fChargeSample
AtChargeWeighted fChargeSample
Definition: AtWeightedGaussian.h:23
RandomSample::AtWeightedGaussian::PDF
virtual std::vector< double > PDF(const AtHit &hit) override
Definition: AtWeightedGaussian.cxx:20
AtHit
Point in space with charge.
Definition: AtHit.h:27