File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
investing_algorithm_framework/domain/backtesting Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change 11from typing import List
22
3- from .backtest import Backtest
43from .backtest_summary_metrics import BacktestSummaryMetrics
54from .backtest_metrics import BacktestMetrics
65
@@ -27,9 +26,7 @@ def safe_weighted_mean(values, weights):
2726 ) / total_weight if total_weight > 0 else None
2827
2928
30- def combine_backtests (
31- backtests : List [Backtest ],
32- ) -> Backtest :
29+ def combine_backtests (backtests ):
3330 """
3431 Combine multiple backtests into a single backtest by aggregating
3532 their results.
@@ -72,6 +69,8 @@ def combine_backtests(
7269 risk_free_rate = backtest .risk_free_rate
7370 break
7471
72+ from .backtest import Backtest
73+
7574 backtest = Backtest (
7675 backtest_summary = summary ,
7776 metadata = metadata ,
You can’t perform that action at this time.
0 commit comments