An array/list of successive same-sign counts.
.same_changes[i] counts how often the same sign was successively observed during update(..., i, change). When the sign flips, .same_changes[i] is reset to 1 or -1.
init
needs to be called before the class instance can be used.
A valid use case is lsc = CountLastSameChanges().init(dimension).
TODO: parameters may need to depend on population size?
Method | __init__ |
Undocumented |
Method | init |
do not overwrite user-set values unless force |
Method | shape |
return value to be added to exponent from change count. |
Method | update |
update same_changes[i] count based on the sign of change |
Instance Variable | chi |
increase chi exponent up to given threshold, can make up for dimension dependent chi |
Instance Variable | chi |
Undocumented |
Instance Variable | parent |
count of the number of changes with the same sign, where |
Instance Variable | same |
Undocumented |
Property | dimension |
Undocumented |
return value to be added to exponent from change count.
return a positive/negative value (or zero) when the last change was respectively postive/negative.
The value is zero for the first chi_exponent_threshold
same changes
and increases linearly for the next chi_exponent_threshold
same changes
and then stays at the threshold value as long as the change does not
flip sign.
increase chi exponent up to given threshold, can make up for dimension dependent chi