Brian, The PositionScore and PositionSize arrays are an efficient way to move data between the backtester phases. I don't control the interface, so I am doing something unusual to stuff more data through a narrow pipe.
If you are writing software from scratch, you can use the appropriate data types for your application -- you have complete control. Packing data is unnecessary unless you have memory constraints. -Steve --- In [email protected], "brian_z111" <brian_z...@...> wrote: > > I have been thinking about this, since I started mulling over how to > design a PowerBackTester > > I will only have to read/write 3 core metrics, in and out of memory > (all other BT metrics can be calc from them on the fly). > > I have price = 1.0277 (2.77 %) > plus in and out time (either datenum or timenum etc depending on base > timeframe). > > I might also need to store additional data with the trades e.g. RSI > value for ranking signals. > > For warp speed I am wondering how to get 3 or more units of data in > one memory series .... I wonder if it would be quicker keep all the > data that belongs to one trade together and thenunpack the serial > data, in RAM, into 3 the or more arrays required i.e. the collection > of arrays that make up the trade matrix? > > Don't know anything about bit consumption per integer etc or > progamming/computers. > > I keep coming back to the idea of making 2 * 32 bits operate like a > pseudo 64 bits (and onwards)? > > Anyone heard of this ... it's probably standard computer practise or > maybe a crazy idea? > > > > > --- In [email protected], Dennis Brown <see3d@> wrote: > > > > How many bits are your numbers? > > > > Two 11 bit integers can be be packed and unpacked from one 32 bit > > float number with ease. You just mask (&) bits to extract the low > > order number. Use multiply or divide to shift the low to the high > > half of the number and back to the low half again. Simple bit > > arithmetic. > > > > Though it seems there should be easier ways to get what you want. > I > > am not a CBT user though. > > > > BR, > > Dennis > > > > > > On Feb 7, 2009, at 7:57 PM, hydroblue@ wrote: > > > > > Thanks Tomasz. I'm looking for a clever way to stuff two numbers > into > > > the 32 bit float and then later extract the 2 numbers. > > > > > > // fraction = 23 bit integer > > > // exponent = 8 bit integer > > > > > > The reason for doing this is to efficiently get an extra array of > > > numbers into the portfolio backtester without thousands of static > vars > > > or Foreign symbols. > > > > > > Is there a way to do this in AFL without writing a DLL? > > > > > > --- In [email protected], "Tomasz Janeczko" <groups@> > > > wrote: > > >> > > >> Hello, > > >> > > >> IEEE 754 Standard floating point (32 bit, single precision) > > >> http://en.wikipedia.org/wiki/IEEE_754-1985 > > >> > > >> Best regards, > > >> Tomasz Janeczko > > >> amibroker.com > > >> ----- Original Message ----- > > >> From: <hydroblue@> > > >> To: <[email protected]> > > >> Sent: Saturday, February 07, 2009 5:13 PM > > >> Subject: [amibroker] AFL floating point number representation? > > >> > > >> > > >>> I need to know what range of values and what precision can be > > >>> represented in the AFL floating point arrays, specifically the > > >>> PositionSize array. > > >>> > > >>> It would also be useful to know how many bits are available in > the > > >>> mantissa and exponent. Any help appreciated. > > >>> > > >>> Thanks, > > >>> Steve > > >>> > > >>> > > >>> > > >>> ------------------------------------ > > >>> > > >>> **** IMPORTANT **** > > >>> This group is for the discussion between users only. > > >>> This is *NOT* technical support channel. > > >>> > > >>> ********************* > > >>> TO GET TECHNICAL SUPPORT from AmiBroker please send an e-mail > > > directly to > > >>> SUPPORT {at} amibroker.com > > >>> ********************* > > >>> > > >>> For NEW RELEASE ANNOUNCEMENTS and other news always check > DEVLOG: > > >>> http://www.amibroker.com/devlog/ > > >>> > > >>> For other support material please check also: > > >>> http://www.amibroker.com/support.html > > >>> > > >>> ********************************* > > >>> Yahoo! Groups Links > > >>> > > >>> > > >>> > > >> > > > > > > > > > > > > > > > ------------------------------------ > > > > > > **** IMPORTANT **** > > > This group is for the discussion between users only. > > > This is *NOT* technical support channel. > > > > > > ********************* > > > TO GET TECHNICAL SUPPORT from AmiBroker please send an e-mail > > > directly to > > > SUPPORT {at} amibroker.com > > > ********************* > > > > > > For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG: > > > http://www.amibroker.com/devlog/ > > > > > > For other support material please check also: > > > http://www.amibroker.com/support.html > > > > > > ********************************* > > > Yahoo! Groups Links > > > > > > > > > > > >
