相关标签:期货交易止损的重要性,黄金交易怎样设止损,期货交易怎么设止损单,外汇交易止损,自动止损止盈交易软件,趋势交易波动止损法,证券交易账号范例,惠比特交易和配种专区,梦三国交易专区,
模型策略源码:VARIABLE: aspect=0; //初始化假定做多头 VARIABLE: stopprice=0;//止损价格变量 VARIABLE: stopnum = 10; //止损价差 RUNMODE:0; //工作于逐周期模式 if barpos = 0 then stopprice := l - stopnum; if aspect = 0 then begin //多头处理 if l <= stopprice then begin //多反空 aspect:= 1; stopprice := h+stopnum; end //处理移动的底部 if l - stopnum > stopprice then stopprice := l-stopnum; end if aspect = 1 then begin //空头处理 if h >= stopprice then begin //空反多 aspect:= 0; stopprice := l-stopnum; end //处理移动的底部 if h + stopnum < stopprice then stopprice := h+stopnum; end //画线 PARTLINE( aspect = 0, stopprice , colorrgb(255,0,0)); PARTLINE( aspect = 1, stopprice , colorrgb(0,255,0)); 点击复制上述代码粘贴到到公式管理器
{别忘了将本网告诉您身边的朋友,向朋友传达有用资料,也是一种人情,你朋友会感谢你的。}