nguyenviettuan96 / mt5_AI_trading_bot

Apply LSTM neural network and reinforcement learning to trading Forex on mt5
16 stars 7 forks source link

system restart on trade #4

Closed samchin89 closed 1 year ago

samchin89 commented 1 year ago

everytime i restart python, it creates a new order, where do i adjust in the code (infer.py) to have a single trade only?

nguyenviettuan96 commented 1 year ago

You consider position_type in this file and fix dict it to only long trade

samchin89 commented 1 year ago

Nguyen, thanks for the guideline. One more, it opens trade every 4 hours, where should I alter to make the RL place 1 trade instead of it placing more orders every 4 hours?

samchin89 commented 1 year ago

hi can i ask, if i start the code(infer.py), and it open a trade with an order id, and if i restart the code, will it remembers the last order id?

nguyenviettuan96 commented 1 year ago

no it only knows these orders that were opened by code it doesn't know previous order.

Vào Th 5, 19 thg 1, 2023 vào lúc 09:44 samchin89 @.***> đã viết:

hi can i ask, if i start the code(infer.py), and it open a trade with an order id, and if i restart the code, will it remembers the last order id?

— Reply to this email directly, view it on GitHub https://github.com/nguyenviettuan96/mt5_AI_trading_bot/issues/4#issuecomment-1396370430, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASKCF535NDSFVHDB3NL2JCDWTCTAJANCNFSM6AAAAAAT6G6ZC4 . You are receiving this because you commented.Message ID: @.***>

samchin89 commented 1 year ago

Nguyen, thanks for the clarification. The code from your repository is wonderful. Thanks for your contribution