Rss & SiteMap

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

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

标题:[求助]帮我看看编写上是否正确

1楼
bbosaabb 发表于:2013/1/14 13:01:55

n1:=barslast(DATE<>REF(DATE,1))+1;

BS6:=(OPENPROFIT<HHV(OPENPROFIT,ENTERBARS)*0.7)&&HHV(OPENPROFIT,ENTERBARS)>300*15&&ENTERBARS>0&&COUNT(HOLDING<>0,n1)>=1;//日内交易,开仓到现在当前浮盈少于最大浮盈时的70%,并且最大浮盈时大于15个点(用于股指回撤止盈)

2楼
bbosaabb 发表于:2013/1/14 13:12:45

还有一个不会编写,麻烦老师帮我编一下

日内1分钟周期的:从当天第一次平仓开始算,当现价大于上一次平仓价10个点开多,少于10个点开空

[此贴子已经被作者于2013-1-14 13:13:29编辑过]
3楼
jinzhe 发表于:2013/1/14 13:19:41

if c>exitprice+10*mindiff then buy;

if c<exitprice-10*mindiff then buyshort;

4楼
bbosaabb 发表于:2013/1/14 13:30:48

if c>exitprice+10*mindiff then buy;

if c<exitprice-10*mindiff then buyshort;

今天的开盘价大于昨天的最后一手单的平仓价10个点时,它就会帮我开多,而我想要的是昨天跟今天分开
5楼
jinzhe 发表于:2013/1/14 13:52:59

variable:a=0;

if cond1 then buy;

if cond2 then buyshort;

if cond3 then begin

sell;

a:=1;

end

 

if cond4 then begin

sellshort;

a:=1;

end

if c>exitprice+10*mindiff and a=1 then buy;

if c<exitprice-10*mindiff and a=1 then buyshort;

if time>=145900 then a:=0;

 

6楼
bbosaabb 发表于:2013/1/14 14:09:35

行了  谢谢

7楼
bbosaabb 发表于:2013/1/14 14:31:02

我第一个问题还未解答啊  帮我一下好吗?

8楼
jinzhe 发表于:2013/1/15 8:52:30

用全局变量记录一下最大浮动盈亏就ok

 

variable: fuying=0;

 

if cond then begin

buy;

fuying:=openprofit;

end

 

if openprofit>fuying then fuying:=openprofit;

 

tiaojian:=  openprofit<=0.7*fuying and fuying>=enterprice+15*mindiff;

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


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