九毛八公式指标
OBV:=EMA(SUM(IF(C>REF(C,1),VOL,IF(C=REF(DIFF,1) AND DEA>=REF(DEA,1)),LINETHICK4,Color0089FF;{//橙} FILLRGN(DIFF,DEA,DIFF>=DEA),Color0089FF;{//橙--加宽} PARTLINE(DIFF,DIFF<=REF(DIFF,1) AND DEA<=REF(DEA,1)),LINETHICK4,COLORBLUE;{//蓝21} FILLRGN(DIFF,DEA,DIFF<=DEA),COLORBLUE;{//蓝--加宽} PARTLINE(DIFF,DIFF>=REF(DIFF,1) AND DEA<=REF(DEA,1)),LINETHICK4,Color00C500;{//绿} PARTLINE(DIFF,DIFF<=REF(DIFF,1) AND DEA>=REF(DEA,1)),LINETHICK4,COLORYELLOW;{//黄} STICKLINE(MACD>ref(MACD,1) and MACD>0,0,MACD,2,0),COLORRED; STICKLINE(MACD0,0,MACD,2,0),COLORYELLOW; STICKLINE(MACDref(MACD,1) and MACD<0,0,MACD,2,0),COLOR0099FF; PARTLINE(2*(DEA-DIFF),C),LINETHICK2,COLORGRAY;{//加速线}
公式模块:
obv:=EMA(SUM(IF(C>REF(C,1),vol,IF(C<REF(C,1),-V,0)),0)/1000,2);
OBVE:=EMA(OBV,3); DIFF:EMA(OBVE,12)-EMA(OBVE,26),LINETHICK4,COLORFF0000; bbdIFF:=DIFF-REF(DIFF,1); DEA:=EMA(DIFF,9); BBDEA:=DEA-REF(DEA,1); macd:=2*(DIFF-DEA); 0,colorwhite; IF(DIFF>=REF(DIFF,1) AND DEA>=REF(DEA,1),DIFF,DRAWNULL),LINETHICK4,COLOR0089FF;{//橙} DRAWBAND(DIFF,RGB(255,90,0),DEA,RGB(0,0,255)); IF(DIFF>=REF(DIFF,1) AND DEA<=REF(DEA,1),DIFF,DRAWNULL),LINETHICK4,COLOR00C500;{//绿} IF(DIFF<=REF(DIFF,1) AND DEA>=REF(DEA,1),DIFF,DRAWNULL),LINETHICK4,coloryellow;{//黄} STICKLINE(MacD>REF(MACD,1) AND MACD>0,0,MACD,0.5,0),colorred; STICKLINE(MACD<REF(MACD,1) AND MACD>0,0,MACD,0.5,0),coloryellow; STICKLINE(MACD<REF(MACD,1) AND MACD<0,0,MACD,0.5,0),colorcyan; STICKLINE(MACD>REF(MACD,1) AND MACD<0,0,MACD,0.5,0),COLOR0099FF; 加速线:2*(DEA-DIFF),LINETHICK2,colorgray;