I'd like this code more if it handled the short side as well as the long side but thanks for the pointer.
--- In [email protected], "pacific5_au" <[EMAIL PROTECTED]> wrote: > > > > > > > > From: binjobingo > > > > > > Sent: Saturday, November 29, 2008 6:28 PM > > > > > > To: [email protected] > > > > > > Subject: [amibroker] SUPER TREND OSCILLATOR > > > > > > > > > > > > > > > > > > Does anybody know the afl for Super trend Oscillator ? > > > > > > > > > > > > http://codebase.mql4.com/4725 > > > > > > > > > > > > Bimbo > > > > > ------------------------------------ > > Try this : > > /* Chandalier Exit (Long Trade) - Geoff Mulhall 30 Dec 2001 */ > /* In Indicator Builder set Scaling = Automatic */ > /* Set Level 0 On, Set Show Dates On, Set Middle On */ > /* Period/Graph = Daily */ > > Title = "Chandalier Exit - Long"; > > /* The following are a guide only and should be optimised */ > ATRMultiplier = 2.5; > ATRRange = 15; > HHVRange = 10; > > /* Graph */ > GraphXSpace = 5; > > MaxGraph=5; > Graph0 = Close; > Graph0Style = 64; > Graph0Color =2; > Graph1Color =4; > Graph1Style =4; > Graph3 = EMA(C,30); > Graph3Style = 1; > Graph3Color =7; > Graph3Style =4; > > > > > Graph1=HHV(High - AtrMultiplier*ATR(ATRRange),HHVRange); > > Buy= Cross(Graph0,Graph1); > > Sell= Cross(Graph1,Graph0); > > Buy = ExRem(Buy,Sell); > Sell = ExRem(Sell,Buy); > > > PlotShapes( shapeUpArrow * Buy, colorBrightGreen ); > > PlotShapes( shapeDownArrow * Sell, colorRed ); >
