diff options
Diffstat (limited to 'algo.py')
-rw-r--r-- | algo.py | 33 |
1 files changed, 33 insertions, 0 deletions
@@ -0,0 +1,33 @@ +from abc import ABC, abstractmethod + +class Algo(ABC): + """ + Function that takes in data nad determined whether to buy, sell, or hold + current position is a float that represents the ratio from liquid to shares that you own + i.e. 1.0 is $0 cash, all shares, 0.0 is max cash, 0 shares + """ + @abstractmethod + def detemine_signal(self, timestamps, prices, current_position): + pass # to implement per algo + + """ + Function that returns an array of go.X plots to merge into graph foir analysis + """ + @abstractmethod + def export_graph(self, graph_data): + pass # to implement per algo + + @property + def name(self): + pass + + @property + def graph_data(self): + pass + + # """ + # Function that takes in data and returns a buy, sell, or hold singal per interval + # """ + # @abstractmethod + # def backtest_algo(self): + # pass
\ No newline at end of file |