Rss & SiteMap

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

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

标题:求教

1楼
zouyingsheng 发表于:2011/8/9 10:25:21

ma4:stkindi('',ma(close,42),0,11);

sell(c<ma4 and holding>0,0,market);
buyshort(close<ma4 and holding=0,1,market);

sellshort(c>ma4 and holding<0,0,market);
buy(close>ma4 and holding=0,1,market);

以上程序问题出在哪?

2楼
26327756l 发表于:2011/8/9 10:27:45

平仓数量上怎么会是 0 .

3楼
zouyingsheng 发表于:2011/8/9 10:28:56
0不就代表全部吗?
4楼
jinzhe 发表于:2011/8/9 10:29:33

ma4:stkindi('','ma.MA1',0,11);//加上一对单引号,然后在MA公式里面把MA1的参数改成42

sell(c<ma4 and holding>0,0,market);
buyshort(close<ma4 and holding=0,1,market);

sellshort(c>ma4 and holding<0,0,market);
buy(close>ma4 and holding=0,1,market);

[此贴子已经被作者于2011-8-9 10:31:39编辑过]
5楼
zouyingsheng 发表于:2011/8/9 10:32:20
谢谢
6楼
zouyingsheng 发表于:2011/8/9 10:52:08

引用昨日当前品种的收盘价呢?

zclose:"close##day";这样对吗?

7楼
fly 发表于:2011/8/9 11:00:25

1.参考问题39

http://www.weistock.com/bbs/dispbbs.asp?boardid=2&Id=49

 

2.或参考函数

CALLSTOCK('if08',VTCLOSE ,6 , -1);//红色改外想引用的品种代码

8楼
zouyingsheng 发表于:2011/8/9 11:10:00
我要的是当前品种的
9楼
jinzhe 发表于:2011/8/9 13:59:45

c2:"if08$close##day";

品种可以改

10楼
zouyingsheng 发表于:2011/8/9 19:53:11

 

CALLSTOCK('if08',VTCLOSE ,6 , -1);

c2:"if08$close##day";

这两条程序可以不指定品种吗?可以的话要怎么该呢?或者还有别的办法。

我的意图是想同一策略监控多个产品的

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


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