Coverage for source/agent/agents/simple_trading_algorithm.py: 80%
5 statements
« prev ^ index » next coverage.py v7.8.0, created at 2025-08-03 19:46 +0000
« prev ^ index » next coverage.py v7.8.0, created at 2025-08-03 19:46 +0000
1# agent/agents/simple_trading_algorithm.py
3# global imports
4import numpy as np
6# local imports
7from source.agent import TradingAlgorithmBase
9class SimpleTradingAlgorithm(TradingAlgorithmBase):
10 """"""
12 def perform_action(self, trend_predictions: int, market_data: np.ndarray = None) -> int:
13 """
14 Performs the trading action based on the trend predictions and market data.
16 Parameters:
17 trend_predictions (np.ndarray): The predicted trends.
18 market_data (np.ndarray): The current market data. This
19 implementation does not use market data.
21 Returns:
22 (int): The result of the trading action.
23 """
25 return trend_predictions