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

[amibroker] Re: Referencing to other indicator



PureBytes Links

Trading Reference Links

Thanks for all of the suggestions, but I can not getting it to work
I tried this:


_SECTION_BEGIN("MACD");
X= RelStrength( "GC" );

SetForeign( "X" );

r1 = Param( "Fast avg", 12, 2, 200, 1 );
r2 = Param( "Slow avg", 26, 2, 200, 1 );
r3 = Param( "Signal avg", 9, 2, 200, 1 );
Plot( ml = MACD(r1, r2), StrFormat(_SECTION_NAME()+"(%g,%g)", r1, 
r2), ParamColor("MACD color", colorRed ), ParamStyle("MACD style") );
Plot( sl = Signal(r1,r2,r3), "Signal" + _PARAM_VALUES(), ParamColor
("Signal color", colorBlue ), ParamStyle("Signal style") );
Plot( ml-sl, "MACD Histogram", ParamColor("Histogram color", 
colorBlack ), styleNoTitle | ParamStyle("Histogram style", 
styleHistogram | styleNoLabel, maskHistogram ) );

RestorePriceArrays();
_SECTION_END();

- But all I am getting is the MACD of the price array insted of the 
MACD of the relative performance indicator.

Any suggestions ?

Andrew




--- In amibroker@xxxxxxxxxxxxxxx, "axium102" <axium102@xxxx> wrote:
>
> Hello;
> 
> I am looking for an example of a formula that would plot an 
indicator 
> from an indicator.
> 
> Precisely I am trying to plot an MACD indicator from a relative 
> performance inicator such as this:
> 
> _SECTION_BEGIN("Relative Performance_Gold");
> X= RelStrength( "GC" );
> Plot(X,"RelStrength",1,1);
> _SECTION_END();
> 
> This indicator plots how a security performs relative to gold. I 
> would like to plot an MACD indicator of that relative performance 
> plot.
> 
> Can please someone help ?
> 
> Alternatively if anybody has something that is close to this - 
please 
> post it so that I can try to modify it.
> 
> Thanks
> 
> 
> Andrew
>







------------------------ Yahoo! Groups Sponsor --------------------~--> 
Try Online Currency Trading with GFT. Free 50K Demo. Trade 
24 Hours. Commission-Free. 
http://us.click.yahoo.com/RvFikB/9M2KAA/U1CZAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

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

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