[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[amibroker] Re: Graham: Last 3 and First 4 trading days of month



PureBytes Links

Trading Reference Links


Graham,

Odd thing...

When I run this test there are large time periods when it doesn't 
trade.  Can't see why this is.  When plotted on the chart, it shows 
all the correct time periods, but when run in a test, there are large 
periods missing.  It will show the correct trades for many years and 
then leave large gaps, sometimes several years in length.

Any idea why?

ts

--- In amibroker@xxxxxxxxxxxxxxx, Graham <kavemanperth@xxxx> wrote:
> sorry typo error on my part
>  SetTradeDelays(0,0,0,0);
>  Buy = Month()!=Ref(Month(),3);
>  Sell = Month()!=Ref(Month(),-3);
> 
> 
> On Thu, 24 Feb 2005 03:45:51 -0000, techsmart <mric@xxxx> wrote:
> > 
> > 
> > I get a syntax error with this:
> > 
> > Any idea what I'm doing wrong?
> > 
> > ts
> > >
> > > settradedelays(0,0,0,0);
> > > Buy = month()|=ref(month(),3);
> > > Sell = month()|=ref(month(),-3);
> > >
> > > Just change the ref values for which days you want either side 
of
> > > month begin/end
> > >
> > >
> > >
> > >
> > > On Tue, 22 Feb 2005 02:51:48 -0000, techsmart <mric@xxxx> wrote:
> > > >
> > > >
> > > > I would like to test holding positions for the last 3 and 
first 4
> > > > trading days of each month.  I'm sure this has been coded in 
AFL
> > > > before.  I looked in the AFL library and didn't find this.
> > > >
> > > > I also can see that the date functions are there in AFL to do 
this
> > > > and if it were just the last 3 and first 4 days of the month,
> > even I
> > > > could code it.  But I want to use actual trading days and 
exclude
> > > > weekends.
> > > >
> > > > Does anyone know if there is code out there for this?  Or how 
it
> > > > would be coded?
> > > >
> > > > ts
> > > >
> > > >
> > > > Check AmiBroker web page at:
> > > > http://www.amibroker.com/
> > > >
> > > > Check group FAQ at:
> > http://groups.yahoo.com/group/amibroker/files/groupfaq.html
> > > > Yahoo! Groups Links
> > > >
> > > >
> > > >
> > > >
> > > >
> > >
> > >
> > > --
> > > Cheers
> > > Graham
> > > http://e-wire.net.au/~eb_kavan/
> > 
> > 
> > Check AmiBroker web page at:
> > http://www.amibroker.com/
> > 
> > Check group FAQ at: 
http://groups.yahoo.com/group/amibroker/files/groupfaq.html
> > Yahoo! Groups Links
> > 
> > 
> > 
> > 
> > 
> 
> 
> -- 
> Cheers
> Graham
> http://e-wire.net.au/~eb_kavan/





------------------------ Yahoo! Groups Sponsor --------------------~--> 
Has someone you know been affected by illness or disease?
Network for Good is THE place to support health awareness efforts!
http://us.click.yahoo.com/Rcy2bD/UOnJAA/cosFAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Check AmiBroker web page at:
http://www.amibroker.com/

Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/amibroker/

<*> 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/