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

[amibroker] Re: can a 15 min bar have a cross(x,y) trigger in the middle of the bar time?



PureBytes Links

Trading Reference Links

Thanks Edward/Graham for the useful responses.  I think I found my problem.  I was looking at trading of FAS/FAZ, which was thinly traded in oct/nov08 timeframes, and did not have a trade always at the end of the 15 min bar...If I look at Jan09 to now...The bars/signals are all correct.

BUT this brings up a great point...This will behave differently with a real-time intraday setting because as Edward said, the close is continuously changing as the bar is being built, until the period is complete.  I will have to look into this.  This is more likely the system that I will be using real-time...waiting for intrabar signals, although the backtest will always show end of bar signals because there are no trades in-between the building of the bar (only, high,low,open,close)

> could be you have not set the analysis window to 15 minute bars, but
> then results would not compare to your charts
> If your charts do not show the bar times that correspond to round 15
> minute values then your preferences can be set to align to market
> hours and to start time of bar
> Also check the database setting is also set to 9:30am start time.
> 
> 
> -- 
> Cheers
> Graham Kav
> AFL Writing Service
> http://www.aflwriting.com
> 
> 
> 
> 2009/4/20 Edward Pottasch <empottasch@xxx>:
> >
> >
> > in real time the close is the last price traded. So within a 15 min bar you
> > may see many signals appear and disappear using your constraint. If you want
> > 1 signal exactly at the cross (an intrabar signal) you need to use:
> >
> > buy = cross(H,EMA(Close,9));
> >
> > if you want to use the close of the 15-min bar when it is finished you use:
> >
> > buy=cross(C, EMA(Close,9)); buy = ref(buy,-1);
> >
> >
> >
> >
> >
> > ----- Original Message -----
> > From: shakerlr
> > To: amibroker@xxxxxxxxxxxxxxx
> > Sent: Monday, April 20, 2009 3:28 AM
> > Subject: [amibroker] can a 15 min bar have a cross(x,y) trigger in the
> > middle of the bar time?
> >
> > I'm pretty new with AB...so bear with me...please.
> >
> > I have created some backtesting strategies where I trade the cross of the 15
> > minute bar as follows:
> >
> > buy=cross(C, EMA(Close,9))
> >
> > I have noticed that I get these signals at times that do NOT cross the bar
> > period...ie, for a backtest I get a signal at:
> >
> > 12:40 pm
> > 2:27 pm
> > 2:11 pm
> > 3:13 pm
> >
> > They seem to be in the middle of a 15 min period, not the end of the bar. Is
> > this possible? Should the close not be the close of the 15 minute bar,
> > aligned on 15 minute periods? Or am I missing something.
> >
> > My trading is from EST timezone, so 9:30 is the start period.
> >
> >
> >
> >
>




------------------------------------

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