Medical Imaging Interaction Toolkit  2022.04.99-194dd5d8
Medical Imaging Interaction Toolkit
mitkPointSetStatisticsCalculator.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 
14 #ifndef _MITK_PointSetSTATISTICSCALCULATOR_H
15 #define _MITK_PointSetSTATISTICSCALCULATOR_H
16 
17 #include <itkObject.h>
19 #include <mitkPointSet.h>
20 
21 namespace mitk
22 {
23 
28 {
29 public:
30 
32  itkFactorylessNewMacro(Self);
33  itkCloneMacro(Self);
34 
36 
38  void SetPointSet(mitk::PointSet::Pointer pSet);
39 
41  mitk::Point3D GetPositionMean();
42 
44  mitk::Vector3D GetPositionStandardDeviation();
45 
47  mitk::Vector3D GetPositionSampleStandardDeviation();
48 
50  double GetPositionErrorMean();
51 
53  double GetPositionErrorStandardDeviation();
54 
56  double GetPositionErrorSampleStandardDeviation();
57 
59  double GetPositionErrorRMS();
60 
62  double GetPositionErrorMedian();
63 
65  double GetPositionErrorMax();
66 
68  double GetPositionErrorMin();
69 
70  //#####################################################################################################
71 
72  //this both methods are used by another class an so they are public... perhaps we want to move them
73  //out of this class because they have nothing to do with point sets.
74 
76  double GetStabw(std::vector<double> list);
77 
79  double GetSampleStabw(std::vector<double> list);
80 
81  //#####################################################################################################
82 
83 
84 protected:
85 
88  ~PointSetStatisticsCalculator() override;
89 
90  // TODO: Remove the std::vector<mitk::Point3D> data structure and use mitk::PointSet everywhere
91 
93  std::vector<double> GetErrorList(std::vector<mitk::Point3D> list);
94 
96  mitk::Point3D GetMean(std::vector<mitk::Point3D> list);
97 
99  std::vector<mitk::Point3D> PointSetToVector(mitk::PointSet::Pointer pSet);
100 
102  bool CheckIfAllPositionsAreEqual();
103 
105 
106  double GetMean(std::vector<double> list);
107 
108  double GetMedian(std::vector<double> list);
109 
110  double GetMax(std::vector<double> list);
111 
112  double GetMin(std::vector<double> list);
113 
114 };
115 
116 }
117 
118 #endif // #define _MITK_PointSetSTATISTICSCALCULATOR_H
#define mitkNewMacro1Param(classname, type)
Definition: mitkCommon.h:68
DataCollection - Class to facilitate loading/accessing structured data.
#define MITKIMAGESTATISTICS_EXPORT
#define mitkClassMacroItkParent(className, SuperClassName)
Definition: mitkCommon.h:45
Class for calculating statistics (like standard derivation, RMS, mean, etc.) for a PointSet...