MCPcopy Create free account

hub / github.com/ZiadFrancis/ReinforcementTrading_Part_1 / functions

Functions22 in github.com/ZiadFrancis/ReinforcementTrading_Part_1

↓ 9 callersMethod_close_position
(self, reason: str, exit_price: float)
trading_env.py:264
↓ 4 callersFunctionevaluate_model
(model: PPO, eval_env: DummyVecEnv, deterministic: bool = True)
train_agent.py:13
↓ 3 callersMethod_get_observation
(self)
trading_env.py:194
↓ 2 callersMethod_compute_unrealized_pips
(self)
trading_env.py:176
↓ 2 callersMethod_open_position
(self, direction: int, sl_pips: float, tp_pips: float)
trading_env.py:232
↓ 2 callersMethod_reset_state
(self)
trading_env.py:146
↓ 2 callersMethod_sample_slippage_pips
(self)
trading_env.py:223
↓ 2 callersFunctionload_and_preprocess_data
Loads EURUSD data from CSV and preprocesses it by adding RELATIVE technical features. CSV expected columns: [Time (EET), Open, High, Low, Cl
indicators.py:5
↓ 2 callersMethodreset
(self, seed=None, options=None)
trading_env.py:348
↓ 2 callersMethodstep
(self, action: int)
trading_env.py:373
↓ 1 callersMethod_apply_optional_normalization
(self, obs: np.ndarray)
trading_env.py:186
↓ 1 callersMethod_check_sl_tp_intrabar_and_maybe_close
Checks SL/TP on the *next bar* range [Low, High]. Conservative rule if both touched: assume SL hits first (worst case). Retur
trading_env.py:304
↓ 1 callersMethod_cost_pips_round_trip
(self)
trading_env.py:228
↓ 1 callersMethod_get_state_features
(self)
trading_env.py:168
↓ 1 callersFunctionmain
()
train_agent.py:41
↓ 1 callersFunctionmain
()
test_agent.py:40
↓ 1 callersFunctionrun_one_episode
(model, vec_env, deterministic=True)
test_agent.py:12
Method__init__
( self, df, window_size: int = 30, sl_options=None, tp_options=None,
trading_env.py:40
Functionmake_test_eval_env
()
train_agent.py:99
Functionmake_train_env
()
train_agent.py:60
Functionmake_train_eval_env
()
train_agent.py:80
Methodrender
(self)
trading_env.py:478