MCPcopy
hub / github.com/ZhengyaoJiang/PGPortfolio / record_history

Method record_history

pgportfolio/tdagent/tdagent.py:54–61  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

52 return first.T
53
54 def record_history(self, x):
55 nx = self.get_last_rpv(x)
56 nx = np.reshape(nx, (1,nx.size))
57 if self.history is None:
58 #self.history = self.get_first_history(x)
59 self.history = nx
60 else:
61 self.history = np.vstack((self.history, nx))
62
63 def get_close(self):
64 '''get close data from relative price

Callers 15

decide_by_historyMethod · 0.80
decide_by_historyMethod · 0.80
decide_by_historyMethod · 0.80
decide_by_historyMethod · 0.80
decide_by_historyMethod · 0.80
get_bMethod · 0.80
decide_by_historyMethod · 0.80
decide_by_historyMethod · 0.80
decide_by_historyMethod · 0.80
decide_by_historyMethod · 0.80
decide_by_historyMethod · 0.80
decide_by_historyMethod · 0.80

Calls 1

get_last_rpvMethod · 0.95

Tested by

no test coverage detected