论坛全局菜单下方 - TICKMILL 285X70论坛全局菜单下方 - ThinkMarkets285X70论坛全局菜单下方 - 荔枝返现285X70论坛全局菜单下方 -  icmarkets285X70
查看:1684回复:7
草龙
注册时间2004-12-17
[MT4指标]自动黄金分割指标
楼主发表于:2014-01-27 06:00只看该作者倒序浏览
1楼 电梯直达
电梯直达
自动显示出当天的黄金分割水平线 主图指标 mt4指标类型:震荡指标 是否能用在mt4手机版上:否 是否含有未来函数:无 //+------------------------------------------------------------------+ //| AutoDayFibs V1.0 | //| | //| Copyright ? 2005, Jason Robinson | //| (jasonrobinsonuk, jnrtrading) | //| http://www.jnrtrading.co.uk | //| | //| Created by jnrtrading | //| | //+------------------------------------------------------------------+ #property copyright "Copyright ? 2005, Jason Robinson (jnrtrading)" #property link "http://www.jnrtrading.co.uk" #property indicator_chart_window extern int daysBackForHigh = 1; extern int daysBackForLow = 1; //---- buffers double Rates[6]; double fib000, fib236, fib382, fib50, fib618, fib100, fib1618, fib2618, fib4236, range, prevRange, high, low; bool objectsExist, highFirst; prevRange = 0; objectsExist = false; //+------------------------------------------------------------------+ //| Custom indicator initialization function | //+------------------------------------------------------------------+ int init() { //---- indicators //prevRange = 0; //objectsExist = false; //---- return(0); } //+------------------------------------------------------------------+ //| Custor indicator deinitialization function | //+------------------------------------------------------------------+ int deinit() { //---- ObjectDelete("fib000"); ObjectDelete("fib000_label"); ObjectDelete("fib236"); ObjectDelete("fib236_label"); ObjectDelete("fib382"); ObjectDelete("fib382_label"); ObjectDelete("fib50"); ObjectDelete("fib50_label"); ObjectDelete("fib618"); ObjectDelete("fib618_label"); ObjectDelete("fib100"); ObjectDelete("fib100_label"); ObjectDelete("fib1618"); ObjectDelete("fib1618_label"); ObjectDelete("fib2618"); ObjectDelete("fib2618_label"); ObjectDelete("fib4236"); ObjectDelete("fib4236_label"); //---- return(0); } //+------------------------------------------------------------------+ //| Custom indicator iteration function | //+------------------------------------------------------------------+ int start() { int i = 0; //---- //Print(prevRange); ArrayCopyRates(Rates, Symbol(), PERIOD_D1); high = Rates[daysBackForHigh][3]; low = Rates[daysBackForLow][2]; range = high - low; while(true) { if(High == high) { highFirst = true; break; } else if(Low == low) { highFirst = false; break; } i++; } //Print(highFirst); // Delete Objects if necessary if (prevRange != range) { ObjectDelete("fib000"); ObjectDelete("fib000_label"); ObjectDelete("fib236"); ObjectDelete("fib236_label"); ObjectDelete("fib382"); ObjectDelete("fib382_label"); ObjectDelete("fib50"); ObjectDelete("fib50_label"); ObjectDelete("fib618"); ObjectDelete("fib618_label"); ObjectDelete("fib100"); ObjectDelete("fib100_label"); ObjectDelete("fib1618"); ObjectDelete("fib1618_label"); ObjectDelete("fib2618"); ObjectDelete("fib2618_label"); ObjectDelete("fib4236"); ObjectDelete("fib4236_label"); objectsExist = false; prevRange = range; //Print("Objects do not exist"); } if (highFirst == true) { fib000 = low; fib236 = (range * 0.236) + low; fib382 = (range * 0.382) + low; fib50 = (high + low) / 2; fib618 = (range * 0.618) + low; fib100 = high; fib1618 = (range * 0.618) + high; fib2618 = (range * 0.618) + (high + range); fib4236 = (range * 0.236) + high + (range * 3); } else if (highFirst == false) { fib000 = high; fib236 = high - (range * 0.236); fib382 = high - (range * 0.382); fib50 = (high + low) / 2; fib618 = high - (range * 0.618); fib100 = low; fib1618 = low - (range * 0.618); fib2618 = (low - range) - (range * 0.618);// + (high + range); fib4236 = low - (range * 3) - (range * 0.236);// + high + (range * 3); } if (objectsExist == false) { ObjectCreate("fib000", OBJ_HLINE, 0, Time[40], fib000); ObjectSet("fib000", OBJPROP_STYLE, STYLE_DASHDOTDOT); ObjectSet("fib000", OBJPROP_COLOR, Orange); ObjectCreate("fib000_label", OBJ_TEXT, 0, Time[0], fib000); ObjectSetText("fib000_label"," 0.0", 8, "Times", Black); ObjectCreate("fib236", OBJ_HLINE, 0, Time[40], fib236); ObjectSet("fib236", OBJPROP_STYLE, STYLE_DASHDOTDOT); ObjectSet("fib236", OBJPROP_COLOR, Orange); ObjectCreate("fib236_label", OBJ_TEXT, 0, Time[0], fib236); ObjectSetText("fib236_label"," 23.6", 8, "Times", Black); ObjectCreate("fib382", OBJ_HLINE, 0, Time[40], fib382); ObjectSet("fib382", OBJPROP_STYLE, STYLE_DASHDOTDOT); ObjectSet("fib382", OBJPROP_COLOR, Orange); ObjectCreate("fib382_label", OBJ_TEXT, 0, Time[0], fib382); ObjectSetText("fib382_label"," 38.2", 8, "Times", Black); ObjectCreate("fib50", OBJ_HLINE, 0, Time[40], fib50); ObjectSet("fib50", OBJPROP_STYLE, STYLE_DASHDOTDOT); ObjectSet("fib50", OBJPROP_COLOR, Orange); ObjectCreate("fib50_label", OBJ_TEXT, 0, Time[0], fib50); ObjectSetText("fib50_label"," 50.0", 8, "Times", Black); ObjectCreate("fib618", OBJ_HLINE, 0, Time[40], fib618); ObjectSet("fib618", OBJPROP_STYLE, STYLE_DASHDOTDOT); ObjectSet("fib618", OBJPROP_COLOR, Orange); ObjectCreate("fib618_label", OBJ_TEXT, 0, Time[0], fib618); ObjectSetText("fib618_label"," 61.8", 8, "Times", Black); ObjectCreate("fib100", OBJ_HLINE, 0, Time[40], fib100); ObjectSet("fib100", OBJPROP_STYLE, STYLE_DASHDOTDOT); ObjectSet("fib100", OBJPROP_COLOR, Orange); ObjectCreate("fib100_label", OBJ_TEXT, 0, Time[0], fib100); ObjectSetText("fib100_label"," 100.0", 8, "Times", Black); ObjectCreate("fib1618", OBJ_HLINE, 0, Time[40], fib1618); ObjectSet("fib1618", OBJPROP_STYLE, STYLE_DASHDOTDOT); ObjectSet("fib1618", OBJPROP_COLOR, Orange); ObjectCreate("fib1618_label", OBJ_TEXT, 0, Time[0], fib1618); ObjectSetText("fib1618_label"," 161.8", 8, "Times", Black); ObjectCreate("fib2618", OBJ_HLINE, 0, Time[40], fib2618); ObjectSet("fib2618", OBJPROP_STYLE, STYLE_DASHDOTDOT); ObjectSet("fib2618", OBJPROP_COLOR, Orange); ObjectCreate("fib2618_label", OBJ_TEXT, 0, Time[0], fib2618); ObjectSetText("fib2618_label"," 261.8", 8, "Times", Black); ObjectCreate("fib4236", OBJ_HLINE, 0, Time[40], fib4236); ObjectSet("fib4236", OBJPROP_STYLE, STYLE_DASHDOTDOT); ObjectSet("fib4236", OBJPROP_COLOR, Orange); ObjectCreate("fib4236_label", OBJ_TEXT, 0, Time[0], fib4236); ObjectSetText("fib4236_label"," 423.6", 8, "Times", Black); //Print("Objects Exist"); } //---- return(0); } //+------------------------------------------------------------------+AutoDayFibs%20V1.0.jpgAutoDayFibs%20V1.0.jpg
TK29帖子1楼右侧xm竖版广告90-240
个性签名

阅尽天下指标
搬砖开始,始于2014

广告
TK30+TK31帖子一樓廣告
TK30+TK31帖子一樓廣告
baigy
注册时间2015-07-12
发表于:2015-07-30 03:48只看该作者
2楼
emoji-imageemoji-image
gunsnw
注册时间2015-01-24
huhuzhu
注册时间2016-01-30
发表于:2016-02-06 06:18只看该作者
4楼
感谢分享
个性签名

韬客社区www.talkfx.co

linxiaohua
注册时间2016-04-04
发表于:2016-04-16 07:14只看该作者
5楼
缺钱,灌水赚通宝,谢谢分享!!
ccs
注册时间2016-04-15
发表于:2016-07-18 13:50只看该作者
6楼
多谢分享
杨粟程
注册时间2017-01-19
发表于:2017-01-21 11:39只看该作者
7楼
谢谢分享 感觉太密拉 这个那个级别的图啊
goodday
注册时间2016-12-06
发表于:2017-04-27 11:14只看该作者
8楼
多谢分享
个性签名

韬客社区www.talkfx.co

本站免责声明:

1、本站所有广告及宣传信息均与韬客无关,如需投资请依法自行决定是否投资、斟酌资金安全及交易亏损风险;

2、韬客是独立的、仅为投资者提供交流的平台,网友发布信息不代表韬客的观点与意思表示,所有因网友发布的信息而造成的任何法律后果、风险与责任,均与韬客无关;

3、金融交易存在极高法律风险,未必适合所有投资者,请不要轻信任何高额投资收益的诱导而贸然投资;投资保证金交易导致的损失可能超过您投入的资金和预期。请您考虑自身的投资经验及风险承担能力,进行合法、理性投资;

4、所有投资者的交易帐户应仅限本人使用,不应交由第三方操作,对于任何接受第三方喊单、操盘、理财等操作的投资和交易,由此导致的任何风险、亏损及责任由投资者个人自行承担;

5、韬客不隶属于任何券商平台,亦不受任何第三方控制,韬客不邀约客户投资任何保证金交易,不接触亦不涉及投资者的任何资金及账户信息,不代理任何交易操盘行为,不向客户推荐任何券商平台,亦不存在其他任何推荐行为。投资者应自行选择券商平台,券商平台的任何行为均与韬客无关。投资者注册及使用韬客即表示其接受和认可上述声明,并自行承担法律风险。

版权所有:韬客外汇论坛 www.talkfx.com 联络我们:[email protected]