ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Acts::FsmwMode1dFinder Class Reference

#include <acts/blob/master/Core/include/Acts/Vertexing/FsmwMode1dFinder.hpp>

Public Member Functions

 FsmwMode1dFinder ()=default
 Default constructor.
 
 FsmwMode1dFinder (double firstFraction, double fraction)
 
Result< double > getMode (std::vector< std::pair< double, double >> inputVector) const
 Function to calculate mode with FSMW algorithm.
 

Private Attributes

double m_firstFraction = 0.5
 
double m_fraction = 0.5
 

Detailed Description

Calculates the mode of a unidimenensional distribution using the Fraction of Sample Mode with Weights algorithm For reference, see: On a Fast, Robust Estimator of the Mode: Comparisons to Other Robust Estimators with Applications, David R. Bickel, Rudolf Fruehwirth, arXiv:math/0505419 It's like an iterative "Half Sample Mode", but the fraction you take at each step can be configured by the user. Configuration possibilities: (1) fraction (default is 50 %) (2) firstFraction (default is 50 %)

Definition at line 32 of file FsmwMode1dFinder.hpp.

View newest version in sPHENIX GitHub at line 32 of file FsmwMode1dFinder.hpp

Constructor & Destructor Documentation

Acts::FsmwMode1dFinder::FsmwMode1dFinder ( )
default

Default constructor.

Acts::FsmwMode1dFinder::FsmwMode1dFinder ( double  firstFraction,
double  fraction 
)

Overload constructor

Parameters
firstFractionfirst fraction in FSMW algorithm
fractionall other fractions in FSMW algorithm

Definition at line 15 of file FsmwMode1dFinder.cpp.

View newest version in sPHENIX GitHub at line 15 of file FsmwMode1dFinder.cpp

Member Function Documentation

Acts::Result< double > Acts::FsmwMode1dFinder::getMode ( std::vector< std::pair< double, double >>  inputVector) const

Function to calculate mode with FSMW algorithm.

Parameters
inputVectorInput collection to calculate mode from
Returns
mode value

Definition at line 18 of file FsmwMode1dFinder.cpp.

View newest version in sPHENIX GitHub at line 18 of file FsmwMode1dFinder.cpp

References a, b, int(), max, and Acts::Test::step().

+ Here is the call graph for this function:

Member Data Documentation

double Acts::FsmwMode1dFinder::m_firstFraction = 0.5
private

Definition at line 52 of file FsmwMode1dFinder.hpp.

View newest version in sPHENIX GitHub at line 52 of file FsmwMode1dFinder.hpp

double Acts::FsmwMode1dFinder::m_fraction = 0.5
private

Definition at line 53 of file FsmwMode1dFinder.hpp.

View newest version in sPHENIX GitHub at line 53 of file FsmwMode1dFinder.hpp


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