thanks sai, but it didn“t worked, perhaps another guy has a formula? thanks
--- In [email protected], "sai20_2000" <[EMAIL PROTECTED]> wrote: > > This is one of the code for angles I had in my archieve > CREDITS to the DEveloper > > Hope this helps > > > //Angle > > > EMA34=EMA(C,20); > Lsma=EMA(C,21); > > PI = atan(1.00) * 4; > periods = 30; > HighHigh =HHV(H, periods); > > LowLow =LLV(L, periods); > > range = 25 / (HighHigh - LowLow) * LowLow; > > x1_EMA34 = 0; > x2_EMA34 = 2; > y1_EMA34 = 0; > y2_EMA34 = (Ref(EMA34, -2) - EMA34) / Avg * range; > > c_EMA34 = sqrt((x2_EMA34 - x1_EMA34)*(x2_EMA34 - x1_EMA34) + > (y2_EMA34 - > y1_EMA34)*(y2_EMA34 - y1_EMA34)); > angle_EMA34 = round(180 * acos((x2_EMA34 - x1_EMA34)/c_EMA34) / PI); > > TitleAngleEMA34 = EncodeColor(colorWhite) + "\nEMA34 angle = "; > > angle_EMA34 = IIf(y2_EMA34 > 0, - angle_EMA34, angle_EMA34); > if(abs(SelectedValue(angle_EMA34)) >= 25) > { > TitleAngleEMA34 = TitleAngleEMA34 + EncodeColor(colorLime); > } > else if(abs(SelectedValue(angle_EMA34)) >= 15) > { > TitleAngleEMA34 = TitleAngleEMA34 + EncodeColor(colorYellow); > } > else > { > TitleAngleEMA34 = TitleAngleEMA34 + EncodeColor(colorRed); > } > TitleAngleEMA34 = TitleAngleEMA34 + angle_EMA34; > // End Angle of EMA34 ****************** > > > Color_ema_20_eangle=TimeFrameExpand( > IIf(angle_ema34>=15,colorBrightGreen,IIf(angle_ema34<=- > 15,colorCustom12, > IIf(angle_ema34>5,colorGreen,IIf(angle_ema34<- > 5,colorRed,colorDarkYellow)))),in5Minute*2); > > > > //Plot Ema and LSMA > pricecolor= IIf(TimeFrameExpand(EMA(C,5),in15Minute*2)> > TimeFrameExpand(Ref(DEMA(C,5),-4),in15Minute*2),colorGreen,colorRed); > //pricecolor= IIf(TimeFrameExpand(TimeFrameCompress(DEMA > (C,5),in15Minute*2),in15Minute*2)> > //TimeFrameExpand(TimeFrameCompress(Ref(DEMA(C,5),- > 4),in15Minute*2),in15Minute*2),colorGreen,colorRed); > // > //Plot(C,"",colorWhite,styleBar); > > > > --- In [email protected], "o_guba" <o_guba@> wrote: > > > > how can write in AB an angle or see, if example a line have a 20 > degree? > > how can i write in AB for example INV TAN? > > haven`t seen anythig in the help menue? > > > > thanks for the answers > > >
