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

[amibroker] Re: if else problem



PureBytes Links

Trading Reference Links

Careful of the line wraps ...

z = CCI(14);

MinBars   = 5;

Plusbars  = BarsSince(z < 0);
Minusbars = BarsSince(z > 0);

Color = IIf(PlusBars >= MinBars, colorBrightGreen, IIf(MinusBars >= 
MinBars, colorRed, colorLightGrey));

GreenBars = BarsSince(Color == colorBrightGreen);
RedBars   = BarsSince(Color == colorRed);

Color2 = IIf(Color == colorLightGrey, IIf(z > 0 AND GreenBars < 
RedBars, colorBrightGreen, IIf(z < 0 AND RedBars < GreenBars, 
colorRed, Color)), Color);

PlotOHLC(O, H, L, C, "CCI Trend", Color2, styleBar);






------------------------ Yahoo! Groups Sponsor --------------------~--> 
What would our lives be like without music, dance, and theater?
Donate or volunteer in the arts today at Network for Good!
http://us.click.yahoo.com/Tcy2bD/SOnJAA/cosFAA/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/