A4:=MA(CLOSE,20);
A5:=(CLOSE > MA(CLOSE,5));
A6:=(MA(CLOSE,5) > MA(CLOSE,10));
A7:=(CLOSE > MA(CLOSE,10));
A8:=(MA(CLOSE,5) > MA(CLOSE,20));
A9:=(CLOSE > MA(CLOSE,20));
A10:=REF(A4,1);
A11:=(A4 > A10);
风向标:MA((((((IF(A5,100,0) + IF(A6,100,0)) + IF(A7,100,0)) + IF(A8,100,0)) + IF(A9,100,0)) + IF(A11,100,0))/6,3.5);
航向: MA(3*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,3,1)-2*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,3,1),3);
扬帆选航:IF(风向标<35 AND 航向<35 AND CROSS(风向标,航向),60,0);
DRAWTEXT(风向标<35 AND 航向<35 AND CROSS(风向标,航向),65,'扬帆');
80, POINTDOT,COLORBLUE,LINETHICK2;
70, POINTDOT,COLORWHITE,LINETHICK2;
20, POINTDOT,COLORGREEN,LINETHICK2;
10, POINTDOT,COLORBLUE,LINETHICK2;