pappsomspp
Library for mass spectrometry
pappso::TraceDetectionMoulon Class Reference

#include <tracedetectionmoulon.h>

Inheritance diagram for pappso::TraceDetectionMoulon:
pappso::TraceDetectionInterface

Public Member Functions

 TraceDetectionMoulon (unsigned int smoothing_half_window_length, pappso_double tic_start, pappso_double tic_stop)
 
 TraceDetectionMoulon (const TraceDetectionMoulon &other)
 
virtual ~TraceDetectionMoulon ()
 
void setFilterMorphoMean (const FilterMorphoMean &smooth)
 
void setTicStart (double tic_start)
 
void setTicStop (double tic_stop)
 
unsigned int getSmoothingHalfEdgeWindows () const
 
pappso_double getTicStart () const
 
pappso_double getTicStop () const
 
void detect (const Trace &xic, TraceDetectionSinkInterface &sink) const override
 

Private Attributes

FilterMorphoMean m_xicFilterSmoothing
 
pappso_double m_ticStart
 
pappso_double m_ticStop
 

Detailed Description

Definition at line 53 of file tracedetectionmoulon.h.

Constructor & Destructor Documentation

◆ TraceDetectionMoulon() [1/2]

pappso::TraceDetectionMoulon::TraceDetectionMoulon ( unsigned int  smoothing_half_window_length,
pappso_double  tic_start,
pappso_double  tic_stop 
)

Definition at line 48 of file tracedetectionmoulon.cpp.

52 {
53  m_xicFilterSmoothing = smooth;
54 }
55 
56 void

◆ TraceDetectionMoulon() [2/2]

pappso::TraceDetectionMoulon::TraceDetectionMoulon ( const TraceDetectionMoulon other)

Definition at line 58 of file tracedetectionmoulon.cpp.

58 {
59  m_ticStart = tic_start;
60 }
61 void
62 TraceDetectionMoulon::setTicStop(double tic_stop)
63 {

◆ ~TraceDetectionMoulon()

pappso::TraceDetectionMoulon::~TraceDetectionMoulon ( )
virtual

Definition at line 65 of file tracedetectionmoulon.cpp.

Member Function Documentation

◆ detect()

void pappso::TraceDetectionMoulon::detect ( const Trace xic,
TraceDetectionSinkInterface sink 
) const
overridevirtual

Implements pappso::TraceDetectionInterface.

Definition at line 106 of file tracedetectionmoulon.cpp.

106  {
107 
108  if((nb_tic_start == 0) && (it_begin != xic.end()) && (banked == false))
109  {
110  // delete(p_current_peak);
111  // p_current_peak = nullptr;
112  it_begin = xic.end();
113  }
114 
115  if(it_smoothed->y >= m_ticStart)
116  {
117  nb_tic_start++;
118  if(it_begin == xic.end())
119  {
120  // p_current_peak = new TracePeak;
121  // p_current_peak->setLeftBoundary(*it_smoothed);
122  it_begin = it;
123  banked = false;
124  }
125  if((nb_tic_start == 2) && (banked == false))
126  {
127  banked = true;
128  }
129  }
130  else
131  {
132  nb_tic_start = 0;
133  }
134  if(it_smoothed->y <= m_ticStop)
135  {
136  if(it_begin != xic.end())
137  {
138 
139  if(banked)
140  {
141  TracePeak peak(it_begin, it + 1);
142  sink.setTracePeak(peak);
143  }
144  banked = false;
145  }
146  }
147  }
148 }
149 } // namespace pappso

References pappso::TraceDetectionSinkInterface::setTracePeak().

◆ getSmoothingHalfEdgeWindows()

unsigned int pappso::TraceDetectionMoulon::getSmoothingHalfEdgeWindows ( ) const

Definition at line 88 of file tracedetectionmoulon.cpp.

88 {
89 
90  Trace xic_smoothed(xic);
91 

◆ getTicStart()

pappso_double pappso::TraceDetectionMoulon::getTicStart ( ) const

Definition at line 94 of file tracedetectionmoulon.cpp.

◆ getTicStop()

pappso_double pappso::TraceDetectionMoulon::getTicStop ( ) const

Definition at line 100 of file tracedetectionmoulon.cpp.

106  {

◆ setFilterMorphoMean()

void pappso::TraceDetectionMoulon::setFilterMorphoMean ( const FilterMorphoMean smooth)

Definition at line 71 of file tracedetectionmoulon.cpp.

75 {

◆ setTicStart()

void pappso::TraceDetectionMoulon::setTicStart ( double  tic_start)

Definition at line 77 of file tracedetectionmoulon.cpp.

81 {

◆ setTicStop()

void pappso::TraceDetectionMoulon::setTicStop ( double  tic_stop)

Definition at line 82 of file tracedetectionmoulon.cpp.

Member Data Documentation

◆ m_ticStart

pappso_double pappso::TraceDetectionMoulon::m_ticStart
private

Definition at line 77 of file tracedetectionmoulon.h.

◆ m_ticStop

pappso_double pappso::TraceDetectionMoulon::m_ticStop
private

Definition at line 78 of file tracedetectionmoulon.h.

◆ m_xicFilterSmoothing

FilterMorphoMean pappso::TraceDetectionMoulon::m_xicFilterSmoothing
private

Definition at line 76 of file tracedetectionmoulon.h.


The documentation for this class was generated from the following files:
pappso::TraceDetectionMoulon::setTicStop
void setTicStop(double tic_stop)
Definition: tracedetectionmoulon.cpp:82
pappso::TraceDetectionMoulon::m_xicFilterSmoothing
FilterMorphoMean m_xicFilterSmoothing
Definition: tracedetectionmoulon.h:76
pappso::TraceDetectionMoulon::m_ticStart
pappso_double m_ticStart
Definition: tracedetectionmoulon.h:77
pappso::TraceDetectionMoulon::m_ticStop
pappso_double m_ticStop
Definition: tracedetectionmoulon.h:78