/// <summary> /// 参数名 类型 说明 /** start_time string 回放行情开始时间,格式:yyyy-mm-dd HH:MM:SS end_time string 回放行情结束时间,格式:yyyy-mm-dd HH:MM:SS initial_cash double 回测初始资金,默认1000000 transaction_ratio double 委托量成交比率,默认1,按委托量全部成交 commission_ratio double 手续费率,默认0,无手续费 slippage_ratio double 滑点比率,默认0,无滑点 price_type int 复权方式,0-不复权,1-前复权 **/ /// </summary> /// <param name="strategy"></param> /// <param name="start_time"></param> /// <param name="end_time"></param> /// <param name="initial_cash"></param> public static void setStrategyBackTestInit(Strategy strategy, string start_time, string end_time, double initial_cash ) { if (initial_cash == 0) { initial_cash = DEFAULT_INITIAL_CASH; } strategy.BacktestConfig(start_time, end_time, initial_cash, 1, 0, 0, 1); }