tensortrade.rewards.simple_profit module

class tensortrade.rewards.simple_profit.SimpleProfit(window_size=1)[source]

Bases: tensortrade.rewards.reward_scheme.RewardScheme

A simple reward scheme that rewards the agent for incremental increases in net worth.

get_reward(portfolio)[source]

Rewards the agent for incremental increases in net worth over a sliding window.

Parameters:portfolio (Portfolio) – The portfolio being used by the environment.
Return type:float
Returns:The cumulative percentage change in net worth over the previous window_size timesteps.
reset()[source]

Optionally implementable method for resetting stateful schemes.