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

Re: [amibroker] Multiple time frames



PureBytes Links

Trading Reference Links

hello,
 
use timeframeexpand(CCI30Min,0.5*inhourly,expandfirst) instead of cci30min in your rule.

 

cheers,Padhu

 



----- Original Message ----
From: Perumal Ramasamy <umrperumal@xxxxxxxxx>
To: amibroker@xxxxxxxxxxxxxxx
Sent: Sunday, September 2, 2007 10:19:07 AM
Subject: [amibroker] Multiple time frames

Hi all,
 
I use 5 min chart  and want to add buy  arrows to my chart which satisfy conditions involving two time frames, as under:
 
1) Price crosses moving average line, on the upside.in 5 min chart
2) CCI indicator is less than -50  in 30 min chart.
 
I tried to make an indicator, but it is not giving the correct result.  While buy arrows are shown, they are not remaining constant at the same place,  They keep changing. 
 
I give below the code :  (My base chart is 5 minutes)
 
TimeFrameSet( 1800);                     //Timeframe set to 30 minutes
CCI30Min = CCI (20);                      // Calculation of 20 periods CCI value in 30 min time frame
TimeFrameRestore( );
 
AveragePrice = MA(Close, 50);
Buy = Cross(Close, AveragePrice) AND CCI30Min < -50 * shapeUpArrow ;
 
Plot(C, "Price", colorBrightGreen, styleCandle) ;         // price plot
PlotShapes(Buy, colorYellow, 0, Low, -10);                 // buy arrow plot
 
Can somebody be kind enough to correct the mistake in the above codes.
 
Thanks for your time.
 
Regards
 
perumal
 
 

__._,_.___

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




Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___