c-rutter / imabc

Home Page:https://c-rutter.github.io/imabc/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Ratchet method

cmaerzluft opened this issue · comments

Here's my attempt to capture the gradual target bound ratcheting (GTBR?) approach that can be both
a) an "emergency use" algorithm to accompany the tot_dist point approach
or
b) act as a standalone approach for reducing current target bounds.

The idea in pseudocode is:
IF current_good_n >= X*N_cov_points (we can adjust this from the current X = 2 to a user defined X if desired)
new ratchet level = 0%
FOR ratchet level 5% to 100% by 5%: (or 10% to 100% by 10%)

(rachet in 0.05 to 1.0 by 0.05)

Tighten all current targets by ratchet level

For each target whose goal bounds have not been reached, for both lower and upper bounds,
calculate the difference between the current bound and the goal bound
move every bound not yet met in by rachet% of this difference
calculate how many points are retained using these narrowed bounds
If more than N_cov_points are retained, then try to narrow bounds further

IF in target points are < N_cov_points
break out of loop
ELSE
new ratchet level = ratchet level
Update current targets by new ratchet levels (for convenience could do this unless new ratchet level = 0%)

revise the code in the ratchet branch to use preferred names for improve_method: percentile (rather than "sample_reduce") and direct (rather than "gtbr").

added in dev branch