Rss & SiteMap

金字塔客服中心 - 专业程序化交易软件提供商 http://www.weistock.com/bbs/

专业程序化软件提供商
共2 条记录, 每页显示 10 条, 页签: [1]
[浏览完整版]

标题:老师,看一下我这套策略写的对不对

1楼
高万福 发表于:2015/10/12 9:28:38

variable:bj=0,n=1,m=2;
variable:t=1,s=2;
Valuewhen(date<>ref(date,1),open);
if open>1*n  and bj=0 and m=n+1 then begin
 buy(1,1,market);
 n:=n+1;
 m:=m+1;
end


if holding>0 and bj=0 and openprofit>=1000 then BEGIN
 sell(1,0,market);
 bj:=1;
end

if open>valuewhen(t=1,close)+1*t and bj=1 and s=t+1 then begin
 buy(1,1,market);
 t:=t+1;
 s:=s+1;
end

if bj=1 and holding>0 and openprofit>=1000 then begin
 sell(1,0,market);
 t:=1;
 s:=2;
end

variable:n=1,m=2;
variable:t=1,s=2;
Valuewhen(date<>ref(date,1),open);;

 

if open<valuewhen(t=1,close)-1*t  and s=t+1 then begin
 buyshort(1,1,market);
 t:=t+1;
 s:=s+1;
end

if holding<0 and openprofit>=1000 then begin
 sellshort(1,0,market);
 t:=1;
 s:=2;
end

variable:bj=0,n=1,m=2;
variable:t=1,s=2;
Valuewhen(date<>ref(date,1),open);
if open>30*n  and bj=0 and m=n+1 then begin
  buyshort(1,1,market);
 n:=n+1;
 m:=m+1;
end

variable:n=1,m=2;
variable:t=1,s=2;
Valuewhen(date<>ref(date,1),open);;

 

if open<valuewhen(t=1,close)-30*t  and s=t+1 then begin
 buy(1,1,market);
 t:=t+1;
 s:=s+1;
end

2楼
jinzhe 发表于:2015/10/12 9:43:44

代码写出来,编译通过了就对

共2 条记录, 每页显示 10 条, 页签: [1]


Powered By Dvbbs Version 8.3.0
Processed in 0.01172 s, 3 queries.