Clipper
|
Resolution ordinal gernerator. More...
#include <resol_basisfn.h>
Public Member Functions | |
void | init (const HKL_info &hklinfo, const ftype &power) |
initialiser: takes an HKL_info and uses all reflections. | |
void | init (const HKL_data_base &hkldata, const ftype &power) |
initialiser: takes an HKL_data & uses non-missing reflections. | |
void | init (const HKL_data_base &hkldata, const Cell &cell, const ftype &power) |
initialiser: takes an HKL_data + Cell & uses non-missing reflections. | |
![]() | |
Generic_ordinal () | |
null constructor | |
Generic_ordinal (const Range< ftype > &range, const int &n) | |
constructor: from range and sampling | |
void | init (const Range< ftype > &range, const int num_ranges=1000) |
initialiser: takes the source range and sampling | |
void | init (const std::vector< ftype > &values, const int num_ranges=1000) |
initialiser: takes the source distibution and a number of bins | |
ftype | ordinal (const ftype &value) const |
return reflection ordinal | |
void | accumulate (const ftype &value) |
accumulate values to build the distribution | |
void | accumulate (const ftype &value, const ftype &weight) |
accumulate values to build the distribution | |
void | prep_ordinal () |
generate the ordinal histogram | |
void | invert () |
invert distribution to get value from ordinal | |
void | init (const int num_ranges=1000) |
DEPRECATED: initialiser: takes a number of bins for histogram. | |
void | add_pass_1 (const ftype &value) |
DEPRECATED: add a value to the distribution (pass 1 of 2) | |
void | add_pass_2 (const ftype &value) |
DEPRECATED: add a value to the distribution (pass 2 of 2) | |
Additional Inherited Members | |
![]() | |
ftype | nranges |
number of ranges | |
Range< ftype > | range_ |
resolution range of data | |
std::vector< ftype > | hist |
histogram of reflections vs resolution | |
Resolution ordinal gernerator.
This class is a helper class for functions which need to divide reflections up by resolution whilst guaranteeing a certain distribution of number of reflections per range. It takes a list of reflections, one at a time, and calculates a function to get the approximate ordinal number of a reflection in a list sorted by resolution.