Skip to content

Commit

Permalink
better naming
Browse files Browse the repository at this point in the history
  • Loading branch information
jbaron committed Apr 9, 2024
1 parent 395ef20 commit 986305e
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion roboquant/strategies/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from .buffer import NumpyBuffer, OHLCVBuffer
from .barstrategy import BarStrategy
from .tastrategy import TaStrategy
from .emacrossover import EMACrossover
from .multistrategy import MultiStrategy
from .smacrossover import SMACrossover
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from roboquant.strategies.strategy import Strategy


class BarStrategy(Strategy):
class TaStrategy(Strategy):
"""Abstract base class for other strategies that helps to implement trading solutions
based on technical indicators using bars.
Expand Down
3 changes: 1 addition & 2 deletions samples/talib_feature.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@

# %%
class RSIFeature(TaFeature):
"""Example using talib to create a RIS feature"""

"""Example using talib to create an RSI feature"""

def __init__(self, *symbols: str, timeperiod=10) -> None:
self.timeperiod = timeperiod
Expand Down
2 changes: 1 addition & 1 deletion samples/talib_strategy.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import roboquant as rq

# %%
class MyStrategy(rq.strategies.BarStrategy):
class MyStrategy(rq.strategies.TaStrategy):
"""Example using talib to create a combined RSI/BollingerBand strategy"""

def _create_signal(self, symbol, ohlcv):
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import unittest

from roboquant.signal import Signal
from roboquant.strategies import BarStrategy, OHLCVBuffer
from roboquant.strategies import TaStrategy, OHLCVBuffer
from tests.common import run_strategy


class _MyStrategy(BarStrategy):
class _MyStrategy(TaStrategy):
"""Example using CandleStrategy to create a custom strategy"""

def _create_signal(self, symbol, ohlcv: OHLCVBuffer) -> Signal | None:
Expand Down

0 comments on commit 986305e

Please sign in to comment.