MA1:=MA(COST(15),1);
TJ:=BArslAST(MA1<C);
TJJ:=BARSLAST(MA1>C);
建仓:SUM(V,TJ)/TJ/100,COLORBLUE;
启动:SUM(V,TJJ)/TJJ/100,COLORGREEN;
DIFF:=EMA(CLOSE,12) - EMA(CLOSE,26);
DEA:=EMA(DIFF,9);
MCD:=2*(DIFF-DEA),COLORSTICK;
AG:=crOSS(DIFF,DEA);
macd1:=SUM(V,BARSLAST(AG)+1)/CAPITAL*200,COLORSTICK;
操作:IF(DEA>REF(DEA,1) AND DIFF>DEA,MacD1,0);