返回列表 发布新帖

有谁能看懂这段程序------vt 的

3181 1
xzf 发表于 2005-12-17 16:05 | 查看全部 阅读模式
https://www.y2cn.com
有哪位大侠能指点,不胜感激!!!

一个很好交易系统,想做一下修改,但看不懂程序不知道命令怎么用?




VT-Fractal Trading System

以下是程序:

{Up and Down Level Fractal}

F1:=ValueWhen(1,H<Ref(H,-2) AND Ref(H,-1)<Ref(H,-2) AND Ref(H,-3)<Ref(H,-2) AND Ref(H,-4)<Ref(H,-2),Ref(H,-2));

F2:=ValueWhen(1,L>Ref(L,-2) AND Ref(L,-1)>Ref(L,-2) AND Ref(L,-3)>Ref(L,-2) AND Ref(L,-4)>Ref(L,-2),Ref(L,-2));

{Cross Up and Down Level Fractal}

a:=Cross(H,F1);
b:=Cross(F2,L);

state:=BarsSince(a)<BarsSince(b);

{Signal Long and Short}

ShortSignal:= state < Ref(state,-1);
LongSignal:= state > Ref(state,-1);

{Trend Up and Down}

UpTrend:=state>0;
DownTrend:=state<1;

{OpenBuy and CloseBuy}

OpenBuy:=LongSignal and (eventCount('OpenBuy')= eventCount('CloseBuy'));
CloseBuy:= ShortSignal and (eventCount('OpenBuy')>eventCount('CloseBuy'));

{OpenSell and CloseSell}

OpenSell:=  ShortSignal and (eventCount('OpenSell')= eventCount('CloseSell'));
CloseSell:=  LongSignal and (eventCount('OpenSell')>eventCount('CloseSell'));

评论1

forexpioneerLv.2 发表于 2005-12-18 12:29 | 查看全部
呵呵,不懂也来关税
回复 点赞

使用道具 举报

回复

本版积分规则

关灯 在本版发帖
扫一扫添加微信客服
QQ客服返回顶部
快速回复 返回顶部 返回列表