股资源-股票学习站-学炒股-股票课程-炒股教程-分析选股指标-入门基础知识

 找回密码
 注册昵称

QQ登录

只需一步,快速开始

搜索
上一主题 下一主题

[大智慧] 大智慧双线持币单线持股+MACD,用就要心悦诚服-指标公式(主图,源码,附图)


    [-----复制链接-----]
楼主
 通达信源码安装路径:1,工具栏点击公式选项。2,弹出公式窗口点击新建。3,把源码复制到指标编辑器保存。4,回到K线图界面安装建立好的公式 || 2020-1-1 12:12:11
[大智慧] 大智慧双线持币单线持股+MACD,用就要心悦诚服-指标公式(主图,源码,附图)

DRAWGBKLAST(v>1,STRIP(RGB(0,40,0),RGB(0,0,0),0));
MA5:MA(CLOSE,5),PRECIS2,COLORred,linethick2;
MA10:MA(CLOSE,10),PRECIS2,color009900,linethick1;
MA20:MA(CLOSE,20),linethick1;
MA30:MA(CLOSE,30),PRECIS2,colorffffFF,linethick1;
{K线}
STICKLINE(CLOSE>OPEN,HIGH,LOW,0.5,0 ),COLOR0000FF;     
STICKLINE(OPEN>=CLOSE,HIGH,LOW,0.5 ,0 ),COLOR00FF00;     
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,8,0 ),COLOR006600;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,7,0 ),COLOR009900;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,5,0 ),COLOR00BB00;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,3,0 ),COLOR00DD00;
STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,1,0 ),COLOR00FF00;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,8,0) ,COLOR000466;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,7,0) ,COLOR000499;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,5,0) ,COLOR0003bb;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,3,0) ,COLOR0002dd;
STICKLINE(CLOSE>OPEN,CLOSE,OPEN,1,0) ,COLOR0001ff;

LC:=REF(C,1);
卖黄金:((SMA(MAX((C - LC),0),3,1) / SMA(ABS((C - LC)),3,1)) * 100),LINETHICK0;
DRAWTEXT(CROSS(80,卖黄金) ,high*1.04,'顶'),COLOR00ffFF,ALIGN1,LINETHICK1;
STICKLINE(CROSS(80,卖黄金) AND C<O,H,L,2,0),COLOR00ffff,LAYER0;
STICKLINE(CROSS(80,卖黄金) AND C<O,C,O,12,0 ),COLOR007777,LAYER0;
STICKLINE(CROSS(80,卖黄金) AND C<O,C,O,8,0 ),COLOR009999,LAYER0;
STICKLINE(CROSS(80,卖黄金) AND C<O,C,O,6,0 ),COLOR00BBBB,LAYER0;
STICKLINE(CROSS(80,卖黄金) AND C<O,C,O,4,0 ),COLOR00DDDD,LAYER0;
STICKLINE(CROSS(80,卖黄金) AND C<O,C,O,2 ,0 ),COLOR00ffff,LAYER0;
双线持币:HHV(MA(HIGH,2),3)*1.08,COLORGREEN,LINETHICK1;
单线持股:LLV(MA(HIGH,2),1)*1.08,COLORRED,LINETHICK2;
FILLRGN(双线持币,单线持股,双线持币>单线持股,RGB(0,0,255)),LINETHICK2,LAYER7;
PARTLINE(单线持股 ,(单线持股>REF(单线持股,1))-1,rgb(0,255,0),1,rgb(255,0,0) ),LINETHICK3,LAYER0;

gj:=if(c=INDEXC,(INDEXC+INDEXh+INDEXl+INDEXO)/4,AMOUNT/(v+0.01)/100);
明日阻力:=l+(gj-l)+(c-l);
明日支撑:=l+(c-gj);
今日阻力:=REF(明日阻力 , 1);
今日支撑:=REF(明日支撑 , 1);
STICKLINE(DISPSTATUS=2  and c>=今日阻力,今日阻力,今日阻力,20,0),ColorRED;
STICKLINE(DISPSTATUS=2  and c<今日阻力,今日阻力,今日阻力,20,0),Color00FFFF;
STICKLINE(DISPSTATUS=2  and c>=今日支撑,今日支撑,今日支撑,20,0),ColorFF00FF;
STICKLINE(DISPSTATUS=2  and c<今日支撑,今日支撑,今日支撑,20,0),Color00ADFF;
DRAWTEXTABS(410,5,'今日支撑:'+NUMTOSTRN(今日支撑 ,2 )),Colorred,linethick5;
DRAWTEXTABS(600,5,'今日阻力:'+NUMTOSTRN(今日阻力 ,2 )),Color00FFFF,linethick5;
X:=BARSLAST(DISPSTATUS=1)+1;
E:=llvall(llv(l,x))*0.95;   
DIFF : EMA(CLOSE,12) - EMA(CLOSE,26),COLOR0000FF,LINETHICK0;
DEA  : EMA(DIFF,9),COLOR00FF00,LINETHICK0;
MACD : 2*(DIFF-DEA),LINETHICK0;
STICKLINE(MACD>0,E+MACD,E,12,0),Color0000FF;
STICKLINE(MACD<0,E+MACD,E,12,0),Color00FF00;
DRAWGBK(DIFF>DEA,STRIP(RGB(0,0,255),RGB(140,0,80),0)),LAYER0;
VERTLINE(CROSS(REF(WMA(C,15),1),WMA(C,15)) AND MACD>0 ,2),LAYER0,COLOR00FFFF



115400mucc02tkpyzksyik.png


回复

举报

QQ|

GMT+8, 2024-11-18 14:48

快速回复 返回顶部 返回列表