1af1db3fec7bad2b8f886158839a092f163b5e83,QUANTAXIS/QACmd/backtest.py,,strategy,#,133

Before Change


    QA.QA_util_log_info(QB.account.sell_available)
    QA.QA_util_log_info("LEFT Cash: %s" % QB.account.cash_available)
    for item in QB.strategy_stock_list:
        QA.QA_util_log_info(
            QB.QA_backtest_get_market_data(QB, item, QB.today).data)  // 如果是分钟回测 用QB.now

        if QB.QA_backtest_hold_amount(QB, item) == 0:  // 如果不持仓
            QB.QA_backtest_send_order(

After Change


    QA.QA_util_log_info(QB.account.sell_available)
    QA.QA_util_log_info("LEFT Cash: %s" % QB.account.cash_available)
    for item in QB.strategy_stock_list:
        market_data=QB.QA_backtest_get_market_data(QB, item, QB.today)
        if market_data is not None:
            QA.QA_util_log_info(market_data.data)
        else:
            QA.QA_util_log_info("{} HAS NO DATA IN {}".format(item,QB.today))// 如果是分钟回测 用QB.now

        if QB.QA_backtest_hold_amount(QB, item) == 0:  // 如果不持仓
            QB.QA_backtest_send_order(
                QB, item, 10000, 1, {"bid_model": "Market"})
        elif QB.QA_backtest_sell_available(QB, item) > 0:  //如果可卖数量大于0
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: QUANTAXIS/QUANTAXIS
Commit Name: 1af1db3fec7bad2b8f886158839a092f163b5e83
Time: 2017-11-12
Author: yutiansut@qq.com
File Name: QUANTAXIS/QACmd/backtest.py
Class Name:
Method Name: strategy


Project Name: QUANTAXIS/QUANTAXIS
Commit Name: 57e877a49ca52e9f39b949e392992b0db29cef16
Time: 2017-06-26
Author: yutiansut@qq.com
File Name: QUANTAXIS/QABacktest/QABacktest.py
Class Name: QA_Backtest
Method Name: __QA_backtest_excute_bid


Project Name: QUANTAXIS/QUANTAXIS
Commit Name: 8d1c4fd714109757a8b5dce18f6664d698359b39
Time: 2017-12-29
Author: 118066038@q.com
File Name: QUANTAXIS/QASU/save_tdx.py
Class Name:
Method Name: QA_SU_save_stock_xdxr