小年1

通达信叠加宝塔线CCI主图指标公式

{20121107}

{一叠加CCI}
零轴:=DYNAINFO(3)*1,COLOR0000FF;
STICKLINE(1,50/200+零轴,50/200+零轴,2,0),COLOR00AA00;
STICKLINE(1,-50/200+零轴,-50/200+零轴,2,0),COLOR00AAAA;
RTYP:=(HIGH+LOW+CLOSE)/3;
CCI14:=(RTYP-MA(RTYP,14))/(0.015*AVEDEV(RTYP,14))/2;
CCI84:=(RTYP-MA(RTYP,84))/(0.015*AVEDEV(RTYP,84))/2;
判顶底CCI14:零轴+CCI14 /200,COLORCCCCCC;
买卖CCI84:零轴+CCI84 /200,COLOR00FFFF,LINETHICK1;
{二均线}
MA5:MA(CLOSE,5),COLOR0000FF,LINETHICK3;
MA10:MA(CLOSE,10),COLORFF00FF,LINETHICK1;
MA30:MA(CLOSE,30),COLORFFFF00,LINETHICK1;
MA60:MA(CLOSE,60),COLOR00FFFF,LINETHICK1;
{三宝塔线}
VAR1:=CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2);
VAR2:=REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR3:=REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR4:=REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR5:=REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR6:=REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR7:=REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR8:=REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR9:=REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARA:=REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VARB:=REF(VARA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARC:=REF(VARB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),2.0,0),COLORRED;
VARD:=CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2);
VARE:=REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARF:=REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR10:=REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR11:=REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR12:=REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR13:=REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR14:=REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR15:=REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR16:=REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR17:=REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR18:=REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),2.0,1),COLORCYAN;{ 收阴}
VAR19:=REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1) AND VAR1;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),3.6,0),COLORFF00FF;{ 买入}
DRAWICON(VAR19,LOW*0.97,1);
VAR1A:=REF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,1) AND VARD;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),3.6,0),COLOR00FFFF;{ 卖出    }
DRAWICON(VAR1A,HIGH*1.02,2);
{数字显示MACD/KDJ CCI指标值}
DRAWRECTREL(0,580,100,960,RGB(150,0,0));
DRAWRECTREL(100,580,200,960,RGB(0,150,150));
DRAWRECTREL(200,725,300,960,RGB(150,0,150));
月K:="KDJ.K#MONTH"(9,3,3);
月D:="KDJ.D#MONTH"(9,3,3);
周K:="KDJ.K#WEEK"(9,3,3);
周D:="KDJ.D#WEEK"(9,3,3);
日K:="KD.K"(9,3,3);
日D:="KD.D"(9,3,3);
DRAWTEXT_FIX(ISLASTBAR,0.04,0.60,0,'KDJ '),COLOR00FFFF;
DRAWTEXT_FIX(ISLASTBAR,0.01,0.65,0,'月K= '),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.05,0.65,0, 月K),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.01,0.7,0,'月D='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.05,0.7,0,月D),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.01,0.75,0,'周K='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.05,0.75,0,周K),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.01,0.8,0,'周D='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.05,0.8,0,周D),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.01,0.85,0,'日K='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.05,0.85,0,日K),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.01,0.9,0,'日D='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.05,0.9,0,日D),COLORFFFFFF;
月DIF:="MACD.DIF#MONTH"(12,26,9);
月DEA:="MACD.DEA#MONTH"(12,26,9);
周DIF:="MACD.DIF#WEEK"(12,26,9);
周DEA:="MACD.DEA#WEEK"(12,26,9);
日DIF:="MACD.DIF"(12,26,9);
日DEA:="MACD.DEA"(12,26,9);
DRAWTEXT_FIX(ISLASTBAR,0.13,0.60,0,'MACD '),COLOR00FFFF;
DRAWTEXT_FIX(ISLASTBAR,0.11,0.65,0,'月DIF= '),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.155,0.65,0, 月DIF),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.11,0.7,0,'月DEA='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.155,0.7,0,月DEA),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.11,0.75,0,'周DIF='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.155,0.75,0,周DIF),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.11,0.8,0,'周DEA='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.155,0.8,0,周DEA),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.11,0.85,0,'日DIF='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.155,0.85,0,日DIF),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.11,0.9,0,'日DEA='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.155,0.9,0,日DEA),COLORFFFFFF;
TYP:=(HIGH+LOW+CLOSE)/3;
日CCI:=(TYP-MA(TYP,84))/(0.015*AVEDEV(TYP,84));
周CCI:=(TYP-MA(TYP,21))/(0.015*AVEDEV(TYP,21));
月CCI:=(TYP-MA(TYP,9))/(0.015*AVEDEV(TYP,9));
DRAWTEXT_FIX(ISLASTBAR,0.235,0.75,0,'CCI'),COLOR00FFFF;
DRAWTEXT_FIX(ISLASTBAR,0.206,0.80,0,'月CC='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.250,0.80,0,月CCI),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.206,0.85,0,'周CCI='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.250,0.85,0,周CCI),COLORFFFFFF;
DRAWTEXT_FIX(ISLASTBAR,0.206,0.90,0,'日CCI='),COLORFFFFFF;
DRAWNUMBER_FIX(ISLASTBAR,0.250,0.90,0,日CCI),COLORFFFFFF;

(0)

相关推荐

  • 让梨树均衡生长没小年

    梨树在我国各地都有种植,梨子也受到很多人的欢迎.而对于梨树种植户来说,梨树的大小年现象是让他们非常头疼的.梨树大小年会严重影响到梨树的产量,降低种植户的经济效益.那么导致梨树大小年的原因是什么呢?又该 ...

  • 过小年,贴灶神!厨房是家中财库,你可别忽视了~

    进入了腊月,春节的氛围就更加浓厚起来了!在民间一般把腊月二十三或腊月二十四称为"小年",这是因为南北方的习俗不同而导致的日子不同. 但无论是在哪一天,小年的到来就标志着春节大幕正式 ...

  • 一个不平凡的小年

    我是一个教书匠~ 每天1个学习.教育.生活的干货 这是灰灰龙的第244篇原创文章 ↑↑点击上方蓝字关注我哈~ 昨天是小年,腊月二十三,是一个不平凡的小年. 感恩,感谢,感激. 01 转线上 前一天晚上 ...

  • 过小年,行大运!小年习俗这样过才有年味!

    腊月是我们每年农历的最后一月,人们常说,过了腊八就是年,而过了腊八,又会迎来小年.这个时候,大部分的人家都会准备新年的各种年货,除此之外,还会打扫祭灶,准备干干净净过个好年. 由于中国地大物博,民族众 ...

  • 今天过小年了

    今天是农历腊月二十三,是农历上的小年,也是"灶神菩萨"上天的日子.有些地方会根据姓氏选择农历二十四这天过小年,具体时间会根据当地风俗略有不同. 在这一天,按照我们这里的风俗,家家户 ...

  • 小年贺岁 | 明清绘画中的灵猴

    文/朱万章 画猴在中国画中属走兽一科.明清以降,专门以画猴著称者,并不多见.就现存作品而论,明清画家中有猴画传世者,大多为职业画家或佚名者,只有少数文人画家参与了猴画的创作."猴" ...

  • 小年,我在文庙留下行走的痕

    清晨,当阵阵鞭炮声响起的时候,我从梦中醒来,发现,阳光已早早地进入房间,候我. 在小年的日子里,我的妻子.我的女儿和我,将要去长春文庙走一走,看一看,听说,在这一天,那里将举行一次公益文化活动. 今冬 ...

  • 今日小年

    行进在时光中  凤舞  诗歌 如若一个人在歌唱 但每个人都听见了自己-- 一月 一月,大地肌肤雪白 冰清玉洁 沉睡不醒,疏枝上缀满了诗歌 等风吹落 杯子里会有些烈酒 梦里会出现花朵 能点燃的,最好都燃 ...

  • 【诗歌】今日,小年

    二零二零 开启鸿运 2020 Happy New Year ● 小年 ● 要穿那件红衬衫 要努力笑得很好看 要去想一生中所有快乐的事 在心里慢慢熔铸 轻轻吐露一句又一句 晶莹的暖 麦芽糖巧克力或花生酥 ...

  • 正月初十过小年,吃饺子

    钱兆金02-21阅读 166互相关注今天是小年,是我们中国传统的小年,家家户户都吃饺子,寓意吉祥.平安,顺利.健康. 饺子,其实就是由馄饨演变而来.在其漫长的发展过程中,名目繁多,古时有"牢 ...