Home › Forums › kdb+ › Convergence using binary? › Re: Convergence using binary?
-
Is this the behavior you’re looking for?
q)t:([] a:100?10;b:100?1.)
q)f:{[x;it]c1:(-1_(>':) (it+1)>x`a),0b; c2: 0.5>abs log ratios next x`b; cond: $[1=it; c1; c1&c2]; delete from x where cond|prev cond}
q)count {f[;y]/[x]}/[t;1 2] 56