Last active
September 6, 2019 03:05
-
-
Save jsrimr/bfdf2364e7aaf02567485f548f56144c to your computer and use it in GitHub Desktop.
concept of trading env
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class TradingEnv: | |
def _long(self,): # buy | |
... | |
def _long_cover(self, current_price_mean, current_mkt_position, action): # sell possession | |
... | |
def step(self, action): | |
... | |
# process buy and sell action | |
# update position of the agent | |
# return next_state and reward | |
return self.obs_return, self.chg_reward[0], done, self.info |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment