TradingStrategyByBk
简述
板块等比策略验证
TradingStrategyByBk(BkNames:Array;BegT:TDateTime;EndT:TDateTime;IndexId:String;BuyCond:Expression;StockBuyCon:Expression;TopType:Integer;TopN:Real;HoldingN:Integer;ReturnType:Integer);TableArray
名称 | 类型 | 说明 |
---|
BkNames | Array | 字符串,以分号分割,板块列表 |
BegT | TDateTime | 日期型时间,板块策略验证开始时间 |
EndT | TDateTime | 日期型时间,板块策略验证截止时间 |
IndexId | String | 字符串,指数代码 |
BuyCond | Expression | 表达式,板块买入条件 |
StockBuyCon | Expression | 表达式,股票选择标准 |
TopType | Integer | 整型,满足的板块取股票方式,含义如下表:
显示名 |
值 |
全部股票 |
0 |
前TopN个股票 |
1 |
前TopN%的股票 |
2 |
|
TopN | Real | 实数,取板块中的股票个数或比例 |
HoldingN | Integer | 整数,持有天数(交易日) |
ReturnType | Integer | 整型,结果返回类型,含义如下表:
显示名 |
值 |
组合指数图形 |
0 |
组合指数数据 |
1 |
原始样本 |
2 |
|
返回 | TableArray | 板块等比策略验证 |
Return TradingStrategyByBk("上证180;中证800",
inttodate(20120625),
inttodate(20121017),
"SH000001",
@BK_UpPercent3()>=60,
@StockZf3(),1,10,10,1);
//结果:
