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

[amibroker] Re: Intraday data, exit at EOD



PureBytes Links

Trading Reference Links

Perfect. Thanks Brian, I appreciate the help, thanks for sharing.

Adrian



--- In amibroker@xxxxxxxxxxxxxxx, "brian_z111" <brian_z111@xxx> wrote:
>
> Cipher,
> 
> Try TimeNum()
> 
> TIMENUM
> - get current bar time Date/Time
> (AFL 2.0)
>  
> 
> SYNTAX  timenum()  
> RETURNS ARRAY  
> FUNCTION  Returns the array with numbers that represent quotation 
> time coded as follows: 
> 10000 * hour + 100 * minute + second, so 12:37:15 becomes 123715  
> EXAMPLE TimeNum()  
> SEE ALSO Hour(), Minute(), Second(), TimeNum() 
> 
> brian_z
> 
> 
> 
> --- In amibroker@xxxxxxxxxxxxxxx, "cipherscribe" 
> <adrian.mollenhorst@> wrote:
> >
> > That's wierd, because when I ask for hour() results in explorer, I 
> get
> > results like 16.00. I tried using the period as well, but it did 
> not help.
> > 
> > So what would be a valid time in AFL for 15:55?
> > 
> > Cipher
> > 
> > 
> > 
> > --- In amibroker@xxxxxxxxxxxxxxx, "brian_z111" <brian_z111@> wrote:
> > >
> > > Hello cipherscribe,
> > > 
> > > 1600 is not a valid time in AFL - you have to put it into the 
> correct 
> > > format as per the EXAMPLE format in hte the AFL Reference Manual
> > > 
> > > HOUR
> > > - get current bar's hour Date/Time
> > > (AFL 2.0)
> > >  
> > > 
> > > SYNTAX  hour()  
> > > RETURNS ARRAY  
> > > FUNCTION  Retrieves current bar's hour  
> > > EXAMPLE Hour()*10000 + Minute() * 100 + Second() 
> > > 
> > > brian_z
> > > 
> > > 
> > > --- In amibroker@xxxxxxxxxxxxxxx, "cipherscribe" 
> > > <adrian.mollenhorst@> wrote:
> > > >
> > > > How can you tell AB to exit a position on the last bar of the 
> day,
> > > > when your working with intraday (5 min) data?
> > > > 
> > > > I have tried things like sell = hour()>1600, and a few other 
> things,
> > > > but always the trades are held over to the next day, until the
> > > > conventional sell signal kicks in....
> > > > 
> > > > Many thanks in advance...
> > > >
> > >
> >
>




Please note that this group is for discussion between users only.

To get 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

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