gym-anytrading
gym-anytrading copied to clipboard
TypeError: Argument 'placement' has incorrect type (expected pandas._libs.internals.BlockPlacement, got slice)
I run the basic example given in the ReadMe and it gives me TypeError: Argument 'placement' has incorrect type (expected pandas._libs.internals.BlockPlacement, got slice)
Import pytz from datetime import datetime, timedelta from gym_mtsim import MtSimulator, OrderType, Timeframe, FOREX_DATA_PATH
sim = MtSimulator( unit='USD', balance=10000., leverage=100., stop_out_level=0.2, hedge=False, )
if not sim.load_symbols(FOREX_DATA_PATH): sim.download_data( symbols=['EURUSD', 'GBPCAD', 'GBPUSD', 'USDCAD', 'USDCHF', 'GBPJPY', 'USDJPY'], time_range=( datetime(2021, 5, 5, tzinfo=pytz.UTC), datetime(2021, 9, 5, tzinfo=pytz.UTC) ), timeframe=Timeframe.D1 ) sim.save_symbols(FOREX_DATA_PATH)