qlib icon indicating copy to clipboard operation
qlib copied to clipboard

workflow example config error

Open bsq1989 opened this issue 8 months ago • 1 comments

📖 Documentation

workflow part of the latest online document, the example config may contain some mistake:

port_analysis_config: &port_analysis_config
    strategy:
        class: TopkDropoutStrategy
        module_path: qlib.contrib.strategy.strategy
        kwargs:
            topk: 50
            n_drop: 5
            signal: <PRED>
    backtest:
        limit_threshold: 0.095
        account: 100000000
        benchmark: *benchmark
        deal_price: close
        open_cost: 0.0005
        close_cost: 0.0015
        min_cost: 5

after i change it to belowe, the test success

port_analysis_config: &port_analysis_config
    strategy:
        class: TopkDropoutStrategy
        module_path: qlib.contrib.strategy
        kwargs:
            topk: 50
            n_drop: 5
            signal: <PRED>
    backtest:
        account: 100000000
        benchmark: *benchmark
        exchange_kwargs:
            limit_threshold: 0.095
            deal_price: close
            open_cost: 0.0005
            close_cost: 0.0015
            min_cost: 5
        start_time: 2025-01-05
        end_time: 2025-04-01

if not, use the origin config to run qrun, may cause qlib.contrib.strategy.strategy not found and deal_price ,open_cost,close_cost,min_cost not recognized

bsq1989 avatar Apr 12 '25 05:04 bsq1989

Hi, @bsq1989 This issue is now fixed in PR 1918, changes are now in effect in the latest documentation, thank you for your interest in qlib and for helping us identify the problem.

SunsetWolf avatar Apr 29 '25 09:04 SunsetWolf