S
.
More...
#include <median_alt.hh>
Public Types | |
typedef S::value | argument |
typedef Accumulator< void > | category |
typedef E | exact_t |
typedef R | q_result |
typedef mln::metal::unqualif < R >::ret | result |
Public Member Functions | |
void | debug__ () const |
bool | is_valid () const |
Check whether this accu is able to return a result. | |
median_alt (const Value_Set< S > &s) | |
R | subj_ () |
template<typename T> | |
void | take_as_init (const T &t) |
Take as initialization the value t . | |
template<typename T> | |
void | take_as_init_ (const T &t) |
Default implementation of "take as initialization". | |
template<typename T> | |
void | take_n_times (unsigned n, const T &t) |
Take n times the value t . | |
template<typename T> | |
void | take_n_times_ (unsigned n, const T &t) |
Default implementation of "take n times". | |
const argument & | to_result () const |
Get the value of the accumulator. | |
void | init () |
void | take (const argument &t) |
Manipulators. | |
void | untake (const argument &t) |
Protected Member Functions | |
void | go_minus_ () |
void | go_plus_ () |
Protected Attributes | |
histo< S > | h_ |
unsigned | i_ |
the median index | |
const S & | s_ |
derived from h_ | |
unsigned | sum_minus_ |
unsigned | sum_plus_ |
argument | t_ |
the median argument |
S
.
Definition at line 54 of file median_alt.hh.
typedef S ::value mln::accu::stat::median_alt< S >::argument |
Definition at line 56 of file median_alt.hh.
typedef Accumulator<void> mln::Accumulator< E >::category [inherited] |
typedef E mln::Object< E >::exact_t [inherited] |
typedef R mln::accu::internal::base< R, E >::q_result [inherited] |
typedef mln::metal::unqualif< R >::ret mln::accu::internal::base< R, E >::result [inherited] |
mln::accu::stat::median_alt< S >::median_alt | ( | const Value_Set< S > & | s | ) | [inline] |
void mln::accu::stat::median_alt< S >::debug__ | ( | ) | const [inline] |
Definition at line 75 of file median_alt.hh.
void mln::accu::stat::median_alt< S >::go_minus_ | ( | ) | [inline, protected] |
Definition at line 290 of file median_alt.hh.
References mln::accu::stat::median_alt< S >::h_, mln::accu::stat::median_alt< S >::i_, mln::accu::stat::median_alt< S >::s_, mln::accu::histo< V >::sum(), mln::accu::stat::median_alt< S >::sum_minus_, mln::accu::stat::median_alt< S >::sum_plus_, and mln::accu::stat::median_alt< S >::t_.
Referenced by mln::accu::stat::median_alt< S >::take(), and mln::accu::stat::median_alt< S >::untake().
void mln::accu::stat::median_alt< S >::go_plus_ | ( | ) | [inline, protected] |
Definition at line 308 of file median_alt.hh.
References mln::accu::stat::median_alt< S >::h_, mln::accu::stat::median_alt< S >::i_, mln::accu::stat::median_alt< S >::s_, mln::accu::histo< V >::sum(), mln::accu::stat::median_alt< S >::sum_minus_, mln::accu::stat::median_alt< S >::sum_plus_, and mln::accu::stat::median_alt< S >::t_.
Referenced by mln::accu::stat::median_alt< S >::take(), and mln::accu::stat::median_alt< S >::untake().
void mln::accu::stat::median_alt< S >::init | ( | ) | [inline] |
Definition at line 262 of file median_alt.hh.
References mln::accu::stat::median_alt< S >::h_, mln::accu::stat::median_alt< S >::i_, mln::accu::histo< V >::init(), mln::accu::stat::median_alt< S >::s_, mln::accu::stat::median_alt< S >::sum_minus_, mln::accu::stat::median_alt< S >::sum_plus_, and mln::accu::stat::median_alt< S >::t_.
Referenced by mln::accu::stat::median_alt< S >::median_alt(), and mln::accu::stat::median_alt< S >::untake().
bool mln::accu::stat::median_alt< S >::is_valid | ( | ) | const [inline] |
Check whether this accu is able to return a result.
Always true here.
Definition at line 282 of file median_alt.hh.
R base::subj_ | ( | ) | [inline, inherited] |
void mln::accu::stat::median_alt< S >::take | ( | const argument & | t | ) | [inline] |
Manipulators.
Definition at line 165 of file median_alt.hh.
References mln::accu::stat::median_alt< S >::go_minus_(), mln::accu::stat::median_alt< S >::go_plus_(), mln::accu::stat::median_alt< S >::h_, mln::accu::stat::median_alt< S >::i_, mln::accu::stat::median_alt< S >::s_, mln::accu::histo< V >::sum(), mln::accu::stat::median_alt< S >::sum_minus_, mln::accu::stat::median_alt< S >::sum_plus_, mln::accu::stat::median_alt< S >::t_, and mln::accu::histo< V >::take().
void mln::Accumulator< E >::take_as_init | ( | const T & | t | ) | [inline, inherited] |
Take as initialization the value t
.
Dev note: this is a final method; override if needed by take_as_init_ (ending with '_').
Reimplemented in mln::accu::stat::variance< T, S, R >.
Definition at line 186 of file accumulator.hh.
References mln::exact(), and mln::mln_exact().
Referenced by mln::morpho::elementary::impl::gradient_on_function(), and mln::morpho::elementary::impl::gradient_on_function_fastest().
void mln::Accumulator< E >::take_as_init_ | ( | const T & | t | ) | [inline, inherited] |
Default implementation of "take as initialization".
Reimplemented in mln::accu::math::inf< T >, mln::accu::math::sum< T, S >, mln::accu::math::sup< T >, mln::accu::pair< A1, A2, T >, mln::accu::rms< T, V >, mln::accu::stat::max< T >, mln::accu::stat::min< T >, mln::accu::stat::rank_high_quant< T >, and mln::accu::stat::var< T >.
Definition at line 200 of file accumulator.hh.
References mln::exact().
void mln::Accumulator< E >::take_n_times | ( | unsigned | n, | |
const T & | t | |||
) | [inline, inherited] |
Take n
times the value t
.
Dev note: this is a final method; override if needed by take_as_init_ (ending with '_').
Definition at line 213 of file accumulator.hh.
References mln::exact(), and mln::mln_exact().
void mln::Accumulator< E >::take_n_times_ | ( | unsigned | n, | |
const T & | t | |||
) | [inline, inherited] |
Default implementation of "take n times".
Reimplemented in mln::accu::stat::var< T >.
Definition at line 230 of file accumulator.hh.
References mln::exact().
const median_alt< S >::argument & mln::accu::stat::median_alt< S >::to_result | ( | ) | const [inline] |
Get the value of the accumulator.
Definition at line 274 of file median_alt.hh.
References mln::accu::stat::median_alt< S >::t_.
void mln::accu::stat::median_alt< S >::untake | ( | const argument & | t | ) | [inline] |
Definition at line 209 of file median_alt.hh.
References mln::accu::stat::median_alt< S >::go_minus_(), mln::accu::stat::median_alt< S >::go_plus_(), mln::accu::stat::median_alt< S >::h_, mln::accu::stat::median_alt< S >::i_, mln::accu::stat::median_alt< S >::init(), mln::accu::histo< V >::sum(), mln::accu::stat::median_alt< S >::sum_minus_, mln::accu::stat::median_alt< S >::sum_plus_, mln::accu::stat::median_alt< S >::t_, and mln::accu::histo< V >::untake().
histo<S> mln::accu::stat::median_alt< S >::h_ [protected] |
Definition at line 85 of file median_alt.hh.
Referenced by mln::accu::stat::median_alt< mln::value::set< T > >::debug__(), mln::accu::stat::median_alt< S >::go_minus_(), mln::accu::stat::median_alt< S >::go_plus_(), mln::accu::stat::median_alt< S >::init(), mln::accu::stat::median_alt< S >::take(), and mln::accu::stat::median_alt< S >::untake().
unsigned mln::accu::stat::median_alt< S >::i_ [protected] |
the median index
Definition at line 92 of file median_alt.hh.
Referenced by mln::accu::stat::median_alt< mln::value::set< T > >::debug__(), mln::accu::stat::median_alt< S >::go_minus_(), mln::accu::stat::median_alt< S >::go_plus_(), mln::accu::stat::median_alt< S >::init(), mln::accu::stat::median_alt< S >::take(), and mln::accu::stat::median_alt< S >::untake().
const S& mln::accu::stat::median_alt< S >::s_ [protected] |
derived from h_
Definition at line 87 of file median_alt.hh.
Referenced by mln::accu::stat::median_alt< S >::go_minus_(), mln::accu::stat::median_alt< S >::go_plus_(), mln::accu::stat::median_alt< S >::init(), and mln::accu::stat::median_alt< S >::take().
unsigned mln::accu::stat::median_alt< S >::sum_minus_ [protected] |
Definition at line 89 of file median_alt.hh.
Referenced by mln::accu::stat::median_alt< mln::value::set< T > >::debug__(), mln::accu::stat::median_alt< S >::go_minus_(), mln::accu::stat::median_alt< S >::go_plus_(), mln::accu::stat::median_alt< S >::init(), mln::accu::stat::median_alt< S >::take(), and mln::accu::stat::median_alt< S >::untake().
unsigned mln::accu::stat::median_alt< S >::sum_plus_ [protected] |
Definition at line 89 of file median_alt.hh.
Referenced by mln::accu::stat::median_alt< mln::value::set< T > >::debug__(), mln::accu::stat::median_alt< S >::go_minus_(), mln::accu::stat::median_alt< S >::go_plus_(), mln::accu::stat::median_alt< S >::init(), mln::accu::stat::median_alt< S >::take(), and mln::accu::stat::median_alt< S >::untake().
argument mln::accu::stat::median_alt< S >::t_ [protected] |
the median argument
Definition at line 94 of file median_alt.hh.
Referenced by mln::accu::stat::median_alt< mln::value::set< T > >::debug__(), mln::accu::stat::median_alt< S >::go_minus_(), mln::accu::stat::median_alt< S >::go_plus_(), mln::accu::stat::median_alt< S >::init(), mln::accu::stat::median_alt< S >::take(), mln::accu::stat::median_alt< S >::to_result(), and mln::accu::stat::median_alt< S >::untake().