PureBytes Links
Trading Reference Links
|
If I understand what you are trying to do, you want to get ami to
plot and evaluate your actual trades, as stored in a database?
It seems to me that you need to set the buy and buyprice arrays from
the values in the database.
Try this:
buyprice = odbcgetarraysql("select price, tradedatetime from rawdata
where symbol='FLWS' and action='buy'");
buy = buyprice != ref(buyprice,-1);
You will also need statements for sellprice, shortprice, coverprice,
etc.
This expoits that fact that where there is no value returned for a
bar, ami will use the value from the last bar. Will not work if two
adjacent trades are at the same price.
--- In amibroker@xxxxxxxxxxxxxxx, "murthysuresh" <money@xxx> wrote:
>
> that is one area i have always felt challenged.
> for eg. i store all my trades in a mysql database. i have always
> wanted to plot the realtime trades. how would you do the following.
> here is the sql that will return my trade info. but running it thro
> ab is something of a challenge for me
>
> select symbol, tradedatetime, action,price from rawdatas where
> symbol='FLWS'
>
> this geneates a list of rows. but how do i get it thro amibroker.
any
> assistance is highly apprecited.
>
> if, i can get it to work properly. i will post it in UKB
> --- In amibroker@xxxxxxxxxxxxxxx, "dloyer123" <dloyer123@> wrote:
> >
> > I just had a good experience using the odbc database driver with
> > amibroker.
> >
> > I built a tick database, about 75GB worth. From that, I can
> calculate
> > volume at price, vwap and other data. I use postgress, a free
open
> > source database.
> >
> > I thought that I would have to write my own trade match and
> backtest
> > code in sql, but then I found the odbc sql interface to pull the
> data
> > into amibroker.
> >
> > I was plesantly surprised how fast the odbc/amibroker interface
> was.
> > Working with tick data is never fast, but each sql query from ami
> was
> > only a handful of ms.
> >
> > -Doug
> >
>
------------------------------------
**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.
TO GET TECHNICAL SUPPORT send an e-mail directly to
SUPPORT {at} amibroker.com
TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)
For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/amibroker/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:amibroker-digest@xxxxxxxxxxxxxxx
mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx
<*> To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|