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

Re: [amibroker] Help with Indicator/Exploration formula



PureBytes Links

Trading Reference Links

Assuming you actually get trade signals, complete the plotshapes functions,
there needs to be input as to where to locate the shapes
See help for what to use in the plotshapes functions

-- 
Cheers
Graham
AB-Write >< Professional AFL Writing Service
Yes, I write AFL code to your requirements
http://www.aflwriting.com

On 08/12/06, areehoi <rhoierman@xxxxxxxxxxxxx> wrote:
>
> I'm trying to get this indicator/exploration to show Buy/Sell signals
> (up ?down arrows) on the indicator and Buy /Sell results on the
> exploration.  Any ideas on how this might be accomplished will be most
> appreciated.
>
> Dick H
> (watch for wrap)
>
> /*ZeroLag W%R*/
> "========";
>
> GraphXSpace = 3;
>
> R = ((HHV(H,14) - C) /(HHV (H,14) -LLV (L,14))) *-100;
>
> MaxGraph=10;
> Period= 10;
> EMA1= EMA(R,Period);
> EMA2= EMA(EMA1,5);
> Difference= EMA1 - EMA2;
> ZeroLagEMA= EMA1 + Difference;
> PR=100-abs(ZeroLagEMA);
>
> Graph0=PR;
>
> MoveAvg=MA(PR,5);
>
>
> //Graph1=MoveAvg;
>
> //Graph1Color=colorTan;
> //Graph0Style=4;//Thick
> MovAvg=MA(PR,5);
> Plot(MA(PR,5),"ZLTrig",colorBlue,styleLine,7,4);
>
> upbar= PR>= MoveAvg AND PR>= Ref(PR,-1) ;
> downbar=(PR < MoveAvg) OR PR>= MoveAvg AND PR< Ref(PR,-1) ;
> barcolor = IIf( downbar,colorRed, IIf( upbar, colorBrightGreen, 7));
> Graph0BarColor = ValueWhen( barcolor != 0, barcolor );
> //dynamic_color = IIf( downbar,colorRed, IIf( upbar, colorBrightGreen,
> 7));
> //Plot(PR,"ZeroLag", Color = ValueWhen( dynamic_color != 0,
> dynamic_color ));
>
> //Graph2=30;
> //Graph3=70;
> HLine =  Param( "Upper Line" , 70, 60,95, 5);
> LLine = Param( "Lower Line", 30, 5, 40, 5);
> Plot( Lline, "", colorPlum,styleLine|styleDashed );
> Plot( Hline, "", colorPlum,styleLine|styleDashed );
>
>
> Graph2Style=Graph3Style=Graph4Style=1;//normal
> Graph4Color=2;
> Graph2Color=5;
> Graph3Color=4;
>
> Graph5=0;
> Graph6=100;
> Graph5Style=Graph6Style=1;
> Graph5Color=Graph6Color=2;//custom
> Buy = Cross(Upbar, MA(PR,5));
> Sell = Cross (MA(PR,5), upbar);
> Buy = ExRem(Buy,Sell);
> Sell = ExRem(Sell,Buy);
> PlotShapes(Buy* shapeUpArrow,colorGreen);
> PlotShapes(Sell* shapeUpArrow,colorRed);
>
> Title=Name()+"  < ZeroLag W%R :"+WriteVal(PR)+"%";
>
> Filter = C <40 AND C >2 AND C> Ref(C,-1)AND Volume > 80000;
> Result = WriteIf(Buy,"Buy","Sell");
> AddTextColumn( WriteIf(Buy,"Buy", "Sell" )
> ,"TRADE",5,IIf(Buy,colorYellow, colorWhite), IIf(Buy, colorDarkGreen,
> colorDarkRed) );
> AddTextColumn(IndustryID(1) ,"     Industry Sector      ", 25.0,
> colorWhite, colorBlue);
> AddColumn( Close, "Close", 1.2, IIf( ROC(C, 1 ) >= 0,
> colorDarkGreen,colorRed ),50 );
> AddColumn(Ref(Close,-1),"Y-Close",1.2, IIf(
> ROC(Ref(C,-1),1)>=0,colorDarkGreen, colorRed ),50 );
> AddColumn( Volume, "Volume", 10.0, IIf( ROC(V, 1 ) >=
> 0,colorDarkGreen, colorRed ) );
> AddColumn( ROC( Close, 1 ), "ROC(1)", 1.2, IIf( ROC(C, 1 ) >=
> 0,colorDarkGreen, colorRed));
>
> Title=Name()+"  < ZeroLag W%R :"+WriteVal(PR)+"%";
>
>
>
>
> 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
>
>
>
>

Content-Description: "AVG certification"
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.432 / Virus Database: 268.15.15/579 - Release Date: 12/7/2006 1:31 PM