下面这个股票指标有点问题,哪位高手帮我修改一下 测试后出现提示:颜色:red设置错误!
M:=55;N:=34;LC:=REF(CLOSE,1);RSI:=((SMA(MAX((CLOSE-LC),0),3,1)/SMA(ABS((CLOSE-LC)),3,...
M:=55;
N:=34;
LC:=REF(CLOSE,1);
RSI:=((SMA(MAX((CLOSE - LC),0),3,1) / SMA(ABS((CLOSE - LC)),3,1)) * 100);
FF:=EMA(CLOSE,3);
MA15:=EMA(CLOSE,21);
DRAWTEXT(CROSS(85,RSI),75,'▼'),COLORGREEN;
VAR1:=IF(YEAR>=2038 AND MONTH>=1,0,1);
VAR2:=REF(LOW,1)*VAR1;
VAR3:=SMA(ABS(LOW-VAR2),3,1)/SMA(MAX(LOW-VAR2,0),3,1)*100*VAR1;
VAR4:=EMA(IF(CLOSE*1.3,VAR3*10,VAR3/10),3)*VAR1;
VAR5:=LLV(LOW,30)*VAR1;
VAR6:=HHV(VAR4,30)*VAR1;
VAR7:=IF(MA(CLOSE,58),1,0)*VAR1;
VAR8:=EMA(IF(LOW<=VAR5,(VAR4+VAR6*2)/2,0),3)/618*VAR7*VAR1;
吸筹:IF(VAR8>100,100,VAR8)*VAR1,COLORRED;
庄家吸筹:STICKLINE(吸筹>-150,0,吸筹,8,0),COLORRED;
散户线: 100*(HHV(HIGH,M)-CLOSE)/(HHV(HIGH,M)-LLV(LOW,M)),COLORFFFF00,LINETHICK2;
RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
J:=3*K-2*D;
庄家线:EMA(J,6),COLORFF00FF,LINETHICK2; 展开
N:=34;
LC:=REF(CLOSE,1);
RSI:=((SMA(MAX((CLOSE - LC),0),3,1) / SMA(ABS((CLOSE - LC)),3,1)) * 100);
FF:=EMA(CLOSE,3);
MA15:=EMA(CLOSE,21);
DRAWTEXT(CROSS(85,RSI),75,'▼'),COLORGREEN;
VAR1:=IF(YEAR>=2038 AND MONTH>=1,0,1);
VAR2:=REF(LOW,1)*VAR1;
VAR3:=SMA(ABS(LOW-VAR2),3,1)/SMA(MAX(LOW-VAR2,0),3,1)*100*VAR1;
VAR4:=EMA(IF(CLOSE*1.3,VAR3*10,VAR3/10),3)*VAR1;
VAR5:=LLV(LOW,30)*VAR1;
VAR6:=HHV(VAR4,30)*VAR1;
VAR7:=IF(MA(CLOSE,58),1,0)*VAR1;
VAR8:=EMA(IF(LOW<=VAR5,(VAR4+VAR6*2)/2,0),3)/618*VAR7*VAR1;
吸筹:IF(VAR8>100,100,VAR8)*VAR1,COLORRED;
庄家吸筹:STICKLINE(吸筹>-150,0,吸筹,8,0),COLORRED;
散户线: 100*(HHV(HIGH,M)-CLOSE)/(HHV(HIGH,M)-LLV(LOW,M)),COLORFFFF00,LINETHICK2;
RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
J:=3*K-2*D;
庄家线:EMA(J,6),COLORFF00FF,LINETHICK2; 展开
2个回答
展开全部
通达信可以用。
你可能不是通达信,修改下颜色red 替换为GREEN试试看。如下:
吸筹:IF(VAR8>100,100,VAR8)*VAR1,COLORGREEN;
庄家吸筹:STICKLINE(吸筹>-150,0,吸筹,8,0),COLORGREEN;
或者是IF语句带乘法运算有问题,替换如下:
吸筹:IF(VAR8>100,100*VAR1,VAR8*VAR1),COLORGREEN;
你可能不是通达信,修改下颜色red 替换为GREEN试试看。如下:
吸筹:IF(VAR8>100,100,VAR8)*VAR1,COLORGREEN;
庄家吸筹:STICKLINE(吸筹>-150,0,吸筹,8,0),COLORGREEN;
或者是IF语句带乘法运算有问题,替换如下:
吸筹:IF(VAR8>100,100*VAR1,VAR8*VAR1),COLORGREEN;
追问
两种方法都试了,仍然不行。
还是出现错误提示:
颜色:green设置错误!
追答
你一定不是通达信软件,且语法中不支持IF语句如此画线方法。
可删除这一行:
吸筹:IF(VAR8>100,100,VAR8)*VAR1,COLORGREEN;
指标照样能用。
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询