summaryrefslogtreecommitdiff
path: root/services/strategy-engine/strategies/rsi_strategy.py
diff options
context:
space:
mode:
authorTheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com>2026-04-01 16:14:11 +0900
committerTheSiahxyz <164138827+TheSiahxyz@users.noreply.github.com>2026-04-01 16:14:11 +0900
commit380b8c079a9f92ece128ecccdff6c62fdef8f3b2 (patch)
treec56414eab6c0ddc4118cb7c6535274b1224ca031 /services/strategy-engine/strategies/rsi_strategy.py
parentc3560fdd637c4f034cac4f7371aeed65d018bc91 (diff)
feat(strategy): add warmup_period to BaseStrategy and YAML config loading
Diffstat (limited to 'services/strategy-engine/strategies/rsi_strategy.py')
-rw-r--r--services/strategy-engine/strategies/rsi_strategy.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/services/strategy-engine/strategies/rsi_strategy.py b/services/strategy-engine/strategies/rsi_strategy.py
index aebbafc..c37957d 100644
--- a/services/strategy-engine/strategies/rsi_strategy.py
+++ b/services/strategy-engine/strategies/rsi_strategy.py
@@ -34,6 +34,10 @@ class RsiStrategy(BaseStrategy):
self._overbought: float = 70.0
self._quantity: Decimal = Decimal("0.01")
+ @property
+ def warmup_period(self) -> int:
+ return self._period + 1
+
def configure(self, params: dict) -> None:
self._period = int(params.get("period", 14))
self._oversold = float(params.get("oversold", 30))