收藏本站 | RSS订阅 股写网-提供股票公式大全,股票公式,公式下载,指标公式
同花顺公式 正文

同花顺CCI黄金坑+主力吸货+CYW,KDJ,MACD多公式组合

时间:2019年12月26日 | 栏目:同花顺公式 | 评论:0 | 点击: 123

这个是同花顺的多公式组合,由CCI黄金坑+主力吸货+CYW,KDJ,MACD多公式组合而成。

 ///DGTF_GSW2018.11.14

// CCI黄金坑+主力吸货+CYW,KDJ,MACD
//RATIO:0-1,0.01
//PASTDAYS:1-10,5
//PINCR:0-11,0.1
//SHORT:1-20,9
//LONG 1:30,17
//VOLINC:2-5,3,暴涨增量比
//COUNTSIGN,3-30.13,统计共振买点数期限
//SIGNRATIO,0-1,0.3,共振买点数比例
// nCOUNT,0-5,3,突均线数,股价突多条均线,表示强势
// BUYSIGNALS 0-8,1,买点信号数
// MINV,0-1,0.5 主力真吸货值,接近0时说明吸货完成
//KEEPDAYS:0-10,3 连增周期
R01=0.98;
R02=1.05;
高安全区=0,colorred;
安全区=20,colorcyan;
HIGHRISK=100,colorgreen;
多方:(L*4+C*3+O*2+H)/10,coloryellow,Linethick1;
空方:EMA(多方,21),colorwhite,Linethick1;
STICKLINE(空方>多方,空方,多方,3,0),colorgreen;
STICKLINE(空方<多方,空方,多方,3,0),colorred;
IF ABS(空方)<10 THEN
R01=0.99;
ELSE IF ABS(空方)<30 THEN
R01=1.0;
ELSE IF ABS(空方)<50 THEN
R01=0.97;
ELSE IF ABS(空方)<100 THEN
R01=1.0;
ELSE R01=0.9;
IF ABS(多方)<10 THEN
{R02=1.0;}
ELSE IF ABS(多方)<30 THEN
{R02=1.0;}
ELSE IF ABS(多方)<50 AND ABS(多方)>=30 THEN
{R02=1.05;}
ELSE IF ABS(多方)<100 THEN
{R02=0.88;}
ELSE R02=0.95;
//R02=1.05;
金叉=CROSS(多方,空方);
死叉=CROSS(空方,多方);
DRAWTEXT(金叉,空方*(R01-0.04),'买'),coloryellow;
DRAWTEXT(死叉,多方*(R02+0.02),'卖'),colorgreen;
DRAWICON(金叉,空方,'buy');
DRAWICON(死叉,空方,'sell');
多方势增:多方>REF(多方,1),nodraw;
空方势增:空方<REF(空方,1),nodraw;
低吸区=(多方势增 AND 空方势增=0) AND (ABS((空方-多方)/ (空方+0.00001)) < Ratio),nodraw ;
STICKLINE(低吸区,多方,空方,5,0),COLOR00FFFF;
DRAWTEXT(低吸区 AND REF(低吸区,1)=0,空方*R01,'吸'),coloryellow;
危险区=(多方势增=0 AND 空方势增>0) AND (ABS((空方-多方)/ (空方+0.00001)) < Ratio),nodraw ;
STICKLINE(危险区,多方,空方,5,0),colorcyan;
DRAWTEXT(危险区 AND REF(危险区,1)=0,多方*R02,'危'),colorwhite;
ZEROS:0,colorwhite,nodraw;
金叉期: =COUNT(金叉,PASTDAYS),nodraw;
死叉期: =COUNT(死叉,PASTDAYS),nodraw;
涨幅:=( (C-REF(CLOSE,1))/REF(CLOSE,1) ),nodraw;
DTGF最佳买点:((金叉 OR 低吸区) AND (涨幅>PINCR) AND (C>=MA(CLOSE,17))) ,colorred,nodraw;
DTGF最佳买点:((金叉 OR 低吸区) AND (C>=MA(CLOSE,17))) ,colorred,nodraw;
DTGF最佳买点期:=COUNT(DTGF最佳买点,PASTDAYS),nodraw;
STICKLINE(DTGF最佳买点,MIN(空方,多方)*0.9,MIN(空方,多方)*0.98,5,0),colorred;
涨停:=(涨幅>=9.9) AND (REF(涨幅,1) <9.9),nodraw;
// 主力真吸货 ////
VAR1:=REF(LOW,1);
VAR2:=SMA(ABS(LOW-VAR1),3,1)/SMA(MAX(LOW-VAR1,0),3,1)*100;
VAR3:=EMA(IF(CLOSE*1.2,VAR2*10,VAR2/10),3);
VAR4:=LLV(LOW,38);
VAR5:=HHV(VAR3,38);
VAR6:=IF(LLV(LOW,90),1,0);
VAR7:=EMA(IF(LOW<=VAR4,(VAR3+VAR5*2)/2,0),3)/618*VAR6;
VAR8:=((C-LLV(L,21))/(HHV(H,21)-LLV(L,21)))*100;
VAR9:=SMA(VAR8,13,8);
主力吸货:VAR7>MINV,nodraw;
//////////////////////
季:=MA(C,60),nodraw,colorcyan;
通:=MA(C,17),nodraw,NOText;
子:=MA(C,26),nodraw,NOText;
午:=MA(C,100),nodraw,NOText;
辰:=MA(C,145),nodraw,NOText;
卯:=MA(C,455),nodraw,NOText;;
申:=MA(C,320),nodraw,NOText;;
亥:=MA(C,732),nodraw,NOText;;
突季:=CROSS(C,季) AND C>REF(C,1),nodraw;
突子:=CROSS(C,子) AND C>REF(C,1),nodraw;
突通:=CROSS(C,通) AND C>REF(C,1),nodraw;
突子:=CROSS(C,子) AND C>REF(C,1),nodraw;
突午:=CROSS(C,子) AND C>REF(C,1),nodraw;
突辰:=CROSS(C,辰) AND C>REF(C,1),nodraw;
突卯:=CROSS(C,卯) AND C>REF(C,1),nodraw;
突申:=CROSS(C,申) AND C>REF(C,1),nodraw;
突亥:=CROSS(C,亥) AND C>REF(C,1),nodraw;
均线最大值:MAX(通,MAX(子,MAX(季,MAX(午,MAX(辰,MAX(卯,MAX(申,亥))))))),nodraw;
突通子:=突通+突子,nodraw;
突均线数:=突通+突季+突子+突午+突辰+突卯+突申+突亥,nodraw;
强突均线=突均线数>=NCOUNT,nodraw;
通线上:=C>通,nodraw;
子线上:=C>子,nodraw;
午线上:=C>午,nodraw;
通子线上:=通线上 AND 子线上 AND 通>=子,nodraw;
通子午线上:=通线上 AND 子线上 AND 午线上 AND 通>=子,nodraw;
疯牛:C>均线最大值,nodraw;// 所有均线上
突均线期:=COUNT(突均线数,PASTDAYS),nodraw;
突通子期:=COUNT(突通子,PASTDAYS),nodraw;
通子金叉:=CROSS(通,子),nodraw;
子午金叉:=CROSS(子,午),nodraw;
小牛初现:=CROSS(通,子) AND (通>REF(通,1)) AND MACD>0 AND CCI>100 AND HIGH> MA(C,5) AND 子>REF(子,1) AND 季>REF(季,1) AND C>季  ,nodraw;
蛟龙出海:=CROSS(子,午) AND (子>REF(子,1)) AND MACD>0 AND CCI>100 AND HIGH> MA(C,5) AND (通>REF(通,1)) AND 午>REF(午,1) AND 季>REF(季,1) AND C>季 ,nodraw;
///// CCI //////////////////
RR8:=MA(CLOSE,27);
RR9:=(CLOSE-RR8)/RR8*100;
RRA:=MA(RR9,2);
RRB:=BARSLAST(CROSS(-10,RRA)=1);
RRD:=RRA<-10 AND RRB>3;
CCI黄金坑:=RRD,nodraw;