[ts-gen] tick decimals

Bill Pippin pippin at owlriver.net
Thu Sep 3 15:13:52 EDT 2009


> for select ticks I am missing some decimals ...

Yes, this is a known problem, dating from the early summer.
Changes to the numeric term object type now require that the shim
adaptively discover the ideal format width for data, or else use
overly high-precision formats everywhere.  The code to adaptively
determine format widths is not yet in place, though it should be
implemented relatively soon.  You are free to choose overly wide
formats yourself for now if you are willing to modify the code.

> ... I vaguely remember there have been ... [posts] ...
> in the past ...

Yes, starting points for reading --- you might look for the posts
that describe Ken's and Richard's changes to their own copies of
the shim --- include:


In brief, you can: patch the format strings in tag.c yourself,
as other users have done, and as is described in some of the
posts above; roll back to approximately the late spring; or wait
for me to implement some form of adaptive formatting.

> ... I would expect 4 decimals ... in the first case and 2 ...
> in the second.

Yes, as you evidently realize, the ideal format width is
symbol-specific.  The best proxy for this value is probably the
contract min_tick value, which is not yet in our database.  Since
that kind of change is probably a ways off, I'm considering a mix
of solutions, including learning the approximate min_tick from the
input prices, capturing the min_tick value from contract data
queries, and providing up-front user control via command bindings.

I'll provide some practical near-term solution --- as opposed to
the long-term ideal of contract min_tick info in the database ---
soon.  As always, the headache in providing the ideal solution is
gathering the data, since under the terms of the account license
we can't redistribute contract data info obtained via the IB tws



More information about the ts-general mailing list