Mantid
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult Class Reference

#include <FitPeaks.h>

Public Member Functions

double getCost (size_t ipeak) const
 
size_t getNumberParameters () const
 
size_t getNumberPeaks () const
 
double getParameterError (size_t ipeak, size_t iparam) const
 get the fitting error of a particular parameter More...
 
double getParameterValue (size_t ipeak, size_t iparam) const
 get the fitted value of a particular parameter More...
 
double getPeakPosition (size_t ipeak) const
 
 PeakFitResult (size_t num_peaks, size_t num_params)
 Holds all of the fitting information for a single spectrum. More...
 
void setBadRecord (size_t ipeak, const double peak_position)
 The peak postition should be negative and indicates what went wrong. More...
 
void setFunctionParameters (size_t ipeak, std::vector< double > &param_values)
 
void setRecord (size_t ipeak, const double cost, const double peak_position, const FitFunction &fit_functions)
 set the peak fitting record/parameter for one peak More...
 

Private Attributes

std::vector< double > m_costs
 
std::vector< double > m_fitted_peak_positions
 
std::vector< std::vector< double > > m_function_errors_vector
 fitted peak and background parameters' fitting error More...
 
size_t m_function_parameters_number
 number of function parameters More...
 
std::vector< std::vector< double > > m_function_parameters_vector
 

Detailed Description

Definition at line 38 of file FitPeaks.h.

Constructor & Destructor Documentation

◆ PeakFitResult()

Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::PeakFitResult ( size_t  num_peaks,
size_t  num_params 
)

Holds all of the fitting information for a single spectrum.

Definition at line 91 of file FitPeaks.cpp.

References m_costs, m_fitted_peak_positions, m_function_errors_vector, and m_function_parameters_vector.

Member Function Documentation

◆ getCost()

double Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::getCost ( size_t  ipeak) const

Definition at line 140 of file FitPeaks.cpp.

References m_costs.

◆ getNumberParameters()

size_t Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::getNumberParameters ( ) const

Definition at line 110 of file FitPeaks.cpp.

References m_function_parameters_number.

◆ getNumberPeaks()

size_t Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::getNumberPeaks ( ) const

Definition at line 112 of file FitPeaks.cpp.

References m_function_parameters_vector.

◆ getParameterError()

double Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::getParameterError ( size_t  ipeak,
size_t  iparam 
) const

get the fitting error of a particular parameter

Parameters
ipeak:: index of the peak in given peak position vector
iparam:: index of the parameter in its corresponding peak profile function
Returns
:: fitting error/uncertain of the specified parameter

Definition at line 121 of file FitPeaks.cpp.

References m_function_errors_vector.

◆ getParameterValue()

double Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::getParameterValue ( size_t  ipeak,
size_t  iparam 
) const

get the fitted value of a particular parameter

Parameters
ipeak:: index of the peak in given peak position vector
iparam:: index of the parameter in its corresponding peak profile function
Returns
:: fitted value of the specified parameter

Definition at line 132 of file FitPeaks.cpp.

References m_function_parameters_vector.

◆ getPeakPosition()

double Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::getPeakPosition ( size_t  ipeak) const

Definition at line 137 of file FitPeaks.cpp.

References m_fitted_peak_positions.

◆ setBadRecord()

void Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::setBadRecord ( size_t  ipeak,
const double  peak_position 
)

The peak postition should be negative and indicates what went wrong.

Parameters
ipeak:: index of the peak in user-specified peak position vector
peak_position:: bad peak position indicating reason of bad fit

Definition at line 175 of file FitPeaks.cpp.

References m_costs, m_fitted_peak_positions, m_function_errors_vector, m_function_parameters_number, and m_function_parameters_vector.

◆ setFunctionParameters()

void Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::setFunctionParameters ( size_t  ipeak,
std::vector< double > &  param_values 
)

◆ setRecord()

void Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::setRecord ( size_t  ipeak,
const double  cost,
const double  peak_position,
const FitFunction fit_functions 
)

Member Data Documentation

◆ m_costs

std::vector<double> Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::m_costs
private

Definition at line 55 of file FitPeaks.h.

Referenced by getCost(), PeakFitResult(), setBadRecord(), and setRecord().

◆ m_fitted_peak_positions

std::vector<double> Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::m_fitted_peak_positions
private

Definition at line 57 of file FitPeaks.h.

Referenced by getPeakPosition(), PeakFitResult(), setBadRecord(), and setRecord().

◆ m_function_errors_vector

std::vector<std::vector<double> > Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::m_function_errors_vector
private

fitted peak and background parameters' fitting error

Definition at line 61 of file FitPeaks.h.

Referenced by getParameterError(), PeakFitResult(), setBadRecord(), and setRecord().

◆ m_function_parameters_number

size_t Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::m_function_parameters_number
private

number of function parameters

Definition at line 53 of file FitPeaks.h.

Referenced by getNumberParameters(), and setBadRecord().

◆ m_function_parameters_vector

std::vector<std::vector<double> > Mantid::Algorithms::FitPeaksAlgorithm::PeakFitResult::m_function_parameters_vector
private

Definition at line 59 of file FitPeaks.h.

Referenced by getNumberPeaks(), getParameterValue(), PeakFitResult(), setBadRecord(), and setRecord().


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