Advertisement
Maurizio-Ciullo

Bot 23 Azionario Meta 60 Min

May 15th, 2025
478
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ////////////////////////////////////////////////////// STRATEGIA FINITA SU AZIONARIO AMERICANO META PARTE 2 DI 2 Azionario Meta 15Min
  2. //////////////////////////////////////////////////////  INIZIO SVILUPPO TIMEFRAME 60 MIN, TEST PORTAFOGLIO 30 MIN "VEDI VIDEO CARTELLA QTA MASTERMIND", APPLICAZIONE STRATEGIA FINALE 15 MIN
  3. // Header e Footer sono solo per il backtest in sample out of sample ricuvuto dallo study, nella strategia non serve può essere eliminato, serve solo per lo sviluppo.
  4.  
  5. ---------------- HEADER INIZIO: DA ELIMINARE ----------------}
  6. Inputs: isSampleOutOfSampleActive(0), displayMode(1);
  7. if isSampleOutOfSampleActive = 0 or (
  8. ((displayMode = 1 or displayMode = 3) and isSampleOutOfSampleActive = 1 and ((Date >= 1120518 and Date <= 1146500) or (Date >= 1163824 and Date <= 1189806) or (Date >= 1207130 and Date <= 1233112) or marketposition <> 0)) or
  9. ((displayMode = 2 or displayMode = 3) and isSampleOutOfSampleActive = 1 and ((Date > 1146501 and Date <= 1163823) or (Date > 1189807 and Date <= 1207129) or (Date > 1233113 and Date <= 1250435) or marketposition <> 0))) then begin
  10. {---------------- HEADER FINE: DA ELIMINARE ----------------}
  11.  
  12. Inputs: be(200);
  13. Vars: n(0);
  14. n = 10000 / Close;
  15.  
  16.  
  17. setStopPosition;
  18.  
  19. if MarketPosition = 0 then begin
  20.     //Il prezzo di chiusura di ieri e' sceso di almeno lo 0.5% rispetto a due giorni fa.
  21.     if (CloseD(1) < CloseD(2) ) then begin
  22.         if ( (HighS(0) - OpenS(0)) > ((HighS(1) - OpenS(1)))) then begin
  23.             buy n shares next bar at market;
  24.         end;
  25.     end;
  26. end;
  27.  
  28. setbreakeven(be);
  29. SetStopLoss(300);
  30. SetProfitTarget(450);
  31.  
  32.  
  33. {---------------- FOOTER INIZIO: DA ELIMINARE ----------------}
  34. end;
  35. {---------------- FOOTER FINE: DA ELIMINARE ----------------}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement