Greetings --
As you are calculating indicators, be wary of any that include angles. Indicators must be invariant to changes in units of measurement. For example, check whether the indicator changes if the stock splits. On Wed, Feb 10, 2016 at 6:01 AM, tsarvjit@yahoo.com [amibroker] <amibroker@yahoogroups.com> wrote:
pls help me in following afl--
EMA13= EMA(C,13);
PI= 3.141593;
HighHigh= HHV(H, 10);
LowLow= LLV(L, 10);
range= 25/(HighHigh - LowLow)*LowLow;
x1= 0;
x2= 2;
y1= 0;
y2= (Ref(EMA13, -2) - EMA13) / ATR(25)*range;
c1= sqrt((x2 - x1)*(x2 - x1) + (y2 - y1)*(y2 - y1));
angle= round(180 * cos((x2 - x1)/c1) / PI);
IIf(y2 > 0, -angle, angle);
EMAcolor = IIf(angle>30 ,colorGreen,colorRed);
Plot( EMA13, "ema13", EMAcolor,styleLine );
Plot( EMA( C, 5 ), _DEFAULT_NAME(), ParamColor( "Color", colorBlue ), ParamStyle("Style") );
I am new to amibroker . Pls tell me how color of ema13 will change when it is more than 30.
thanks in advance .
__._,_.___
Posted by: Howard B <howardbandy@gmail.com>
| Reply via web post | • | Reply to sender | • | Reply to group | • | Start a New Topic | • | Messages in this topic (2) |
**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.
TO GET TECHNICAL SUPPORT send an e-mail directly to
SUPPORT {at} amibroker.com
TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)
For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/
This group is for the discussion between users only.
This is *NOT* technical support channel.
TO GET TECHNICAL SUPPORT send an e-mail directly to
SUPPORT {at} amibroker.com
TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)
For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/
.
__,_._,___

EmoticonEmoticon