EMA20:EMA(C,20);
DRAWCOLORKLINE(C>EMA20,COLORRED,1);
DRAWCOLORKLINE(C<EMA20,COLORBLACK,1);
MA60:EMA(C,60);
MA500:EMA(C,509);
MA5:EMA(C,5);
MA26:EMA(C,26);

TJ1:=MA60<MA500&&C<MA60&&CROSSDOWN(MA5,MA26);
TJ2:=MA60>MA500&&C>MA60&&CROSS(MA5,MA26);

DRAWCOLORKLINE(L>MA500,COLORRED,0);
DRAWCOLORKLINE(H<MA500,COLORCYAN,0);
DRAWCOLORKLINE(MA500>=L&&MA500<=H,COLORYELLOW,0);