Medical Imaging Interaction Toolkit  2018.4.99-389bf124
Medical Imaging Interaction Toolkit
mitkMaximumCurveDescriptionParameter.cpp
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 
14 #include <algorithm>
15 
16 const std::string mitk::MaximumCurveDescriptionParameter::PARAMETER_NAME = "MaximumConcentrationUptake";
17 
19 {
20 }
21 
23 {
24 }
25 
27 {
29  return result;
30 }
31 
33 {
35  CurveDescriptionParameterResultType maximum = itk::NumericTraits<CurveDescriptionParameterResultType>::NonpositiveMin();
36  int steps = grid.GetSize();
37 
38  for (int i = 0; i < steps - 1; ++i)
39  {
40  maximum = std::max(maximum, curve(i));
41  }
42 
43  results.push_back(maximum);
44  return results;
45 }
DescriptionParameterNamesType GetDescriptionParameterName() const override
std::vector< CurveDescriptionParameterResultType > DescriptionParameterResultsType
DescriptionParameterResultsType ComputeCurveDescriptionParameter(const CurveType &curve, const CurveGridType &grid) const override
static T max(T x, T y)
Definition: svm.cpp:56
std::vector< CurveDescriptionParameterNameType > DescriptionParameterNamesType