Maurizio-Ciullo

Bot 5 Strategia BRKJPY Forex

May 8th, 2022 (edited)
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
  2. // © Maurizio-Ciullo
  3. // Strategia Della Quant Trader academy da testare e ottimizzare su altri sotostanti e
  4.  
  5. //@version=5
  6. strategy("Bot BRKJPY GBP/JPY Forex Ver-5 Breakout 30M LONG E SHORT", overlay=true, margin_long=100, margin_short=100 )
  7.  
  8.  
  9. massimi = ta.highest(high[1], 50)
  10. minimi = ta.lowest(low[1], 50)
  11. plot(massimi)
  12. plot(minimi)
  13.  
  14. // Con "GMT+2" Prendo L'orario Corrente E Non L'orario Della Borsa
  15. longCondition = close > massimi and hour(time, "GMT+2") > 13 and hour(time, "GMT+2") < 18
  16. if longCondition
  17.     strategy.entry("long", strategy.long)
  18.     strategy.exit("long", profit=2250, loss=600)
  19.    
  20. shortCondition =  close < minimi and hour(time, "GMT+2") > 13 and hour(time, "GMT+2") < 18
  21. if longCondition
  22.     strategy.entry("short", strategy.long)
  23.     strategy.exit("short", profit=2250, loss=600)
Add Comment
Please, Sign In to add comment