Recentemente sono arrivato a una conclusione su come gli indicatori tipo Zigzago possono essere usati nel tester (e anche nella vita reale). Risulta (da considerazioni logiche, non l'ho ancora testato) - molto semplice. Così semplice che mi sono chiesto come ho fatto a non indovinarlo prima. :)
E ZigZag, è lo stesso NRTR ... :)) O trailing stop (l'uscita "lampadario") ... :)) O entrando su un pullback dal basso ... .......... ecc. ecc.
Paproboval ja sdelat' funkciju SetArrow() iz mt3 s pomos4ju ObjectFind()->ObjectDelete();ObjectCreate()->ObjectSet() v svajom custom indikator. Jiesli podkliu4aju indikator priamo k grafiku, vsio rabotajet i strelki risujetsia. Ho provato a evo zapustit' 4erez iCustom() funkciju in eksperte i zapustit' 4erez tester i vylez takaya oshbybka:
Pri vyzove indikatora 4erez iCustom() funkciju ObjectFind() i ObjectCreate() in indikatore otkazalis' rabotat' in tester i vale. Strelki nirisujetsia, i indikator prekras4ajet lavoro.
Po kodu oshbybki posmotrel v biblioteku stdlib, i tam eto vyvoditsia kak "unknown command" pri ObjectCreate().
La struttura vyzova takaja: ekspert->indikator->vyzovov svojej sdelannoj funkciji SetArrow(Time[shift],Price,Code,Color)->udalajem staruju strelku jiesli imia novoj strelku nie unikal'naja s pomos4ju ObjectFind()+ObjectDelete() jiesli da->doajem ObjectCreate() con imenenem stringa vziatovo iz Time, patom ObjectSet() param Objectrov dlia strelki.
Mozete poset' tam proisxit posle kampilirovanija?
Jiesli budet nuzna eta funkcija i sami ninapishyte, pribavliu posze. :-)
P.S. SetArrow() funkciji nigde netu v MT4, bylo by o4en' polezno jiesli ya by okazalas' v spiske standartnyx funkcijax. I jies4io: quando l'esperto/individuatore del katorom si trova in un ciclo di ve4nyj, MT4 sozrajet vsie resursy i zavisajet, eto kak nibut' nuzno popravit'. Ideja nad etom - sdelat' parametr skol'ko ciklovno mozno byt' v te4enije adnoj sekundy, tipa CPU prioritet :-)
Gli indicatori chiamati tramite iCustom non disegnano nulla da nessuna parte. iCustom può solo restituire valori dai buffer degli indicatori. Inoltre, state cercando di chiamare la funzione attraverso iCustom? È impossibile...
Dovete salvare questa funzione in un file header nella cartella /include Poi inseriscilo nel tuo Expert Advisor/indicatore #include <stdlib.mqh> e nel blocco start() ci si può riferire ad esso come inline. Io la vedo così.
Quando eseguo il tester ottengo occasionalmente un errore comune, di cosa si tratta?
Anche strani registri multilinea come :
<br / translate="no"> 19:14:22 2004.02.27 10:37 Tester: take profit #5 a 1.2412 (1.2406 / 1.2410) 19:14:22 2004.02.27 10:38 Tester: take profit #5 a 1.2412 (1.2401 / 1.2405) 19:14:22 2004.02.27 10:39 Tester: take profit #5 a 1.2412 (1.2400 / 1.2404) 19:14:22 2004.02.27 10:40 Tester: take profit #5 a 1.2412 (1.2401 / 1.2405) 19:14:22 2004.02.27 10:41 Tester: take profit #5 a 1,2412 (1,2398 / 1,2402) 19:14:22 2004.02.27 10:42 Tester: take profit #5 a 1.2412 (1.2400 / 1.2404) 19:14:22 2004.02.27 10:43 Tester: take profit #5 a 1.2412 (1.2400 / 1.2404) 19:14:22 2004.02.27 10:44 Tester: take profit #5 a 1.2412 (1.2399 / 1.2403) 19:14:22 2004.02.27 10:45 Tester: take profit #5 a 1.2412 (1.2402 / 1.2406) 19:14:22 2004.02.27 10:46 Tester: take profit #5 a 1.2412 (1.2399 / 1.2403) 19:14:22 2004.02.27 10:47 Tester: take profit #5 a 1.2412 (1.2397 / 1.2401) 19:14:22 2004.02.27 10:48 Tester: take profit #5 a 1,2412 (1,2391 / 1,2395) 19:14:22 2004.02.27 10:49 Tester: take profit #5 a 1.2412 (1.2393 / 1.2397) 19:14:22 2004.02.27 10:50 Tester: take profit #5 a 1.2412 (1.2395 / 1.2399) 19:14:22 2004.02.27 10:51 Tester: take profit #5 a 1.2412 (1.2394 / 1.2398) 19:14:22 2004.02.27 10:52 Tester: take profit #5 a 1,2412 (1,2391 / 1,2395) 19:14:22 2004.02.27 10:53 Tester: take profit #5 a 1.2412 (1.2393 / 1.2397) 19:14:22 2004.02.27 10:54 Tester: take profit #5 a 1.2412 (1.2399 / 1.2403) 19:14:22 2004.02.27 10:55 Tester: take profit #5 a 1.2412 (1.2402 / 1.2406) 19:14:22 2004.02.27 10:56 Tester: take profit #5 a 1.2412 (1.2394 / 1.2398) 19:14:22 2004.02.27 10:57 Tester: take profit #5 a 1,2412 (1,2387 / 1,2391) 19:14:22 2004.02.27 10:58 Tester: take profit #5 a 1,2412 (1,2387 / 1,2391) 19:14:22 2004.02.27 10:59 Tester: take profit #5 a 1,2412 (1,2385 / 1,2389) 19:14:22 2004.02.27 11:00 Tester: take profit #5 a 1,2412 (1,2385 / 1,2389) 19:14:22 2004.02.27 11:01 Tester: take profit #5 a 1.2412 (1.2390 / 1.2394) 19:14:22 2004.02.27 11:02 Tester: take profit #5 a 1.2412 (1.2393 / 1.2397) 19:14:22 2004.02.27 11:03 Tester: take profit #5 a 1,2412 (1,2391 / 1,2395) 19:14:22 2004.02.27 11:04 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388) 19:14:22 2004.02.27 11:05 Tester: take profit #5 a 1.2412 (1.2385 / 1.2389) 19:14:22 2004.02.27 11:06 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388) 19:14:22 2004.02.27 11:07 Tester: take profit #5 a 1.2412 (1.2381 / 1.2385) 19:14:22 2004.02.27 11:08 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388) 19:14:22 2004.02.27 11:09 Tester: take profit #5 a 1.2412 (1.2378 / 1.2382) 19:14:22 2004.02.27 11:10 Tester: take profit #5 a 1.2412 (1.2379 / 1.2383) 19:14:22 2004.02.27 11:11 Tester: take profit #5 a 1.2412 (1.2383 / 1.2387) 19:14:22 2004.02.27 11:12 Tester: take profit #5 a 1,2412 (1,2385 / 1,2389) 19:14:22 2004.02.27 11:13 Tester: take profit #5 a 1,2412 (1,2378 / 1,2382) 19:14:22 2004.02.27 11:14 Tester: take profit #5 a 1.2412 (1.2377 / 1.2381) 19:14:22 2004.02.27 11:15 Tester: take profit #5 a 1.2412 (1.2381 / 1.2385) 19:14:22 2004.02.27 11:16 Tester: take profit #5 a 1.2412 (1.2382 / 1.2386) 19:14:22 2004.02.27 11:17 Tester: take profit #5 a 1.2412 (1.2380 / 1.2384) 19:14:22 2004.02.27 11:18 Tester: take profit #5 a 1,2412 (1,2384 / 1,2388) 19:14:22 2004.02.27 11:19 Tester: take profit #5 a 1,2412 (1,2385 / 1,2389) 19:14:22 2004.02.27 11:20 Tester: take profit #5 a 1.2412 (1.2382 / 1.2386) 19:14:22 2004.02.27 11:21 Tester: take profit #5 a 1,2412 (1,2377 / 1,2381) 19:14:22 2004.02.27 11:22 Tester: take profit #5 a 1.2412 (1.2379 / 1.2383) 19:14:22 2004.02.27 11:23 Tester: take profit #5 a 1.2412 (1.2383 / 1.2387) 19:14:22 2004.02.27 11:24 Tester: take profit #5 a 1.2412 (1.2383 / 1.2387) 19:14:22 2004.02.27 11:25 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388) 19:14:22 2004.02.27 11:26 Tester: take profit #5 a 1.2412 (1.2387 / 1.2391) 19:14:22 2004.02.27 11:27 Tester: take profit #5 a 1.2412 (1.2386 / 1.2390) 19:14:22 2004.02.27 11:28 Tester: take profit #5 a 1,2412 (1,2384 / 1,2388) 19:14:22 2004.02.27 11:29 Tester: take profit #5 a 1.2412 (1.2385 / 1.2389) 19:14:22 2004.02.27 11:30 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388) 19:14:22 2004.02.27 11:31 Tester: take profit #5 a 1.2412 (1.2380 / 1.2384) 19:14:22 2004.02.27 11:32 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388) 19:14:22 2004.02.27 11:33 Tester: take profit #5 a 1.2412 (1.2385 / 1.2389) 19:14:22 2004.02.27 11:34 Tester: take profit #5 a 1.2412 (1.2386 / 1.2390) 19:14:22 2004.02.27 11:35 Tester: take profit #5 a 1.2412 (1.2386 / 1.2390) 19:14:22 2004.02.27 11:36 Tester: take profit #5 a 1.2412 (1.2388 / 1.2392)
Allo stesso tempo è chiaro che i test non funzionano correttamente. Questo non è per offendere gli sviluppatori, ma per il bene della causa - per far funzionare tutto correttamente il prima possibile.
In questo caso, è chiaro che i test non funzionano correttamente. <br / translate="no"> Questo non è per offendere gli sviluppatori, ma per il bene della causa - affinché tutto funzioni correttamente il più presto possibile.
Siamo solo per questo bene - per portare il tester a regime :)
Consenti l'uso dei cookie per accedere al sito MQL5.com.
Abilita le impostazioni necessarie nel browser, altrimenti non sarà possibile accedere.
Hai effettuato l'accesso. L'autenticazione a due fattori è stata disattivata. Configurala di nuovo e scansiona un nuovo codice QR, oppure continua con l'autenticazione a due fattori disattivata.
(non nel tester funziona bene)
Forse consigliare come calcolare il canale di regressione in modo diverso?
Ho detto ovunque che lo ZigZag standard è indesiderabile da infilare in un EA per il backtesting. Il graal sarà ordinario.
A quanto pare non sono stato ovunque :)
Motivare. Non è ovvio dal codice come viene usato.
E ZigZag, è lo stesso NRTR ... :))
O trailing stop (l'uscita "lampadario") ... :))
O entrando su un pullback dal basso ...
.......... ecc. ecc.
Fondamentalmente è tutto lo stesso... :)
U menia sledus4aja situacija:
Paproboval ja sdelat' funkciju SetArrow() iz mt3 s pomos4ju ObjectFind()->ObjectDelete();ObjectCreate()->ObjectSet() v svajom custom indikator. Jiesli podkliu4aju indikator priamo k grafiku, vsio rabotajet i strelki risujetsia. Ho provato a evo zapustit' 4erez iCustom() funkciju in eksperte i zapustit' 4erez tester i vylez takaya oshbybka:
Pri vyzove indikatora 4erez iCustom() funkciju ObjectFind() i ObjectCreate() in indikatore otkazalis' rabotat' in tester i vale. Strelki nirisujetsia, i indikator prekras4ajet lavoro.
Po kodu oshbybki posmotrel v biblioteku stdlib, i tam eto vyvoditsia kak "unknown command" pri ObjectCreate().
La struttura vyzova takaja:
ekspert->indikator->vyzovov svojej sdelannoj funkciji SetArrow(Time[shift],Price,Code,Color)->udalajem staruju strelku jiesli imia novoj strelku nie unikal'naja s pomos4ju ObjectFind()+ObjectDelete() jiesli da->doajem ObjectCreate() con imenenem stringa vziatovo iz Time, patom ObjectSet() param Objectrov dlia strelki.
Mozete poset' tam proisxit posle kampilirovanija?
Jiesli budet nuzna eta funkcija i sami ninapishyte, pribavliu posze. :-)
P.S. SetArrow() funkciji nigde netu v MT4, bylo by o4en' polezno jiesli ya by okazalas' v spiske standartnyx funkcijax. I jies4io: quando l'esperto/individuatore del katorom si trova in un ciclo di ve4nyj, MT4 sozrajet vsie resursy i zavisajet, eto kak nibut' nuzno popravit'. Ideja nad etom - sdelat' parametr skol'ko ciklovno mozno byt' v te4enije adnoj sekundy, tipa CPU prioritet :-)
int ArrowSize=1; #include <stdlib.mqh> void SetArrow(datetime ArrowTime, double Price, double ArrowCode, color ArrowCollor) { int err; string ArrowName = DoubleToStr(ArrowTime,0); if (ObjectFind(ArrowName) != -1) ObjectDelete(ArrowName); if(!ObjectCreate(ArrowName, OBJ_ARROW, 0, ArrowTime, Price)) { err=GetLastError(); Print("error: can't create Arrow! codice #",err," ",ErrorDescription(err)); return; } else { ObjectSet(ArrowName, OBJPROP_ARROWCODE, ArrowCode); ObjectSet(ArrowName, OBJPROP_COLOR , ArrowCollor); ObjectSet(ArrowName, OBJPROP_WIDTH , ArrowSize); ObjectsRedraw(); }Po4emu eto nirabotajet 4erez iCustom() i rabotajet priamo iz indikatora nimogu poimat'... Mozete pamo4'?
iCustom può solo restituire valori dai buffer degli indicatori.
Inoltre, state cercando di chiamare la funzione attraverso iCustom?
È impossibile...
Poi inseriscilo nel tuo Expert Advisor/indicatore
#include <stdlib.mqh>
e nel blocco start() ci si può riferire ad esso come inline.
Io la vedo così.
Anche strani registri multilinea come :
19:14:22 2004.02.27 10:37 Tester: take profit #5 a 1.2412 (1.2406 / 1.2410)
19:14:22 2004.02.27 10:38 Tester: take profit #5 a 1.2412 (1.2401 / 1.2405)
19:14:22 2004.02.27 10:39 Tester: take profit #5 a 1.2412 (1.2400 / 1.2404)
19:14:22 2004.02.27 10:40 Tester: take profit #5 a 1.2412 (1.2401 / 1.2405)
19:14:22 2004.02.27 10:41 Tester: take profit #5 a 1,2412 (1,2398 / 1,2402)
19:14:22 2004.02.27 10:42 Tester: take profit #5 a 1.2412 (1.2400 / 1.2404)
19:14:22 2004.02.27 10:43 Tester: take profit #5 a 1.2412 (1.2400 / 1.2404)
19:14:22 2004.02.27 10:44 Tester: take profit #5 a 1.2412 (1.2399 / 1.2403)
19:14:22 2004.02.27 10:45 Tester: take profit #5 a 1.2412 (1.2402 / 1.2406)
19:14:22 2004.02.27 10:46 Tester: take profit #5 a 1.2412 (1.2399 / 1.2403)
19:14:22 2004.02.27 10:47 Tester: take profit #5 a 1.2412 (1.2397 / 1.2401)
19:14:22 2004.02.27 10:48 Tester: take profit #5 a 1,2412 (1,2391 / 1,2395)
19:14:22 2004.02.27 10:49 Tester: take profit #5 a 1.2412 (1.2393 / 1.2397)
19:14:22 2004.02.27 10:50 Tester: take profit #5 a 1.2412 (1.2395 / 1.2399)
19:14:22 2004.02.27 10:51 Tester: take profit #5 a 1.2412 (1.2394 / 1.2398)
19:14:22 2004.02.27 10:52 Tester: take profit #5 a 1,2412 (1,2391 / 1,2395)
19:14:22 2004.02.27 10:53 Tester: take profit #5 a 1.2412 (1.2393 / 1.2397)
19:14:22 2004.02.27 10:54 Tester: take profit #5 a 1.2412 (1.2399 / 1.2403)
19:14:22 2004.02.27 10:55 Tester: take profit #5 a 1.2412 (1.2402 / 1.2406)
19:14:22 2004.02.27 10:56 Tester: take profit #5 a 1.2412 (1.2394 / 1.2398)
19:14:22 2004.02.27 10:57 Tester: take profit #5 a 1,2412 (1,2387 / 1,2391)
19:14:22 2004.02.27 10:58 Tester: take profit #5 a 1,2412 (1,2387 / 1,2391)
19:14:22 2004.02.27 10:59 Tester: take profit #5 a 1,2412 (1,2385 / 1,2389)
19:14:22 2004.02.27 11:00 Tester: take profit #5 a 1,2412 (1,2385 / 1,2389)
19:14:22 2004.02.27 11:01 Tester: take profit #5 a 1.2412 (1.2390 / 1.2394)
19:14:22 2004.02.27 11:02 Tester: take profit #5 a 1.2412 (1.2393 / 1.2397)
19:14:22 2004.02.27 11:03 Tester: take profit #5 a 1,2412 (1,2391 / 1,2395)
19:14:22 2004.02.27 11:04 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388)
19:14:22 2004.02.27 11:05 Tester: take profit #5 a 1.2412 (1.2385 / 1.2389)
19:14:22 2004.02.27 11:06 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388)
19:14:22 2004.02.27 11:07 Tester: take profit #5 a 1.2412 (1.2381 / 1.2385)
19:14:22 2004.02.27 11:08 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388)
19:14:22 2004.02.27 11:09 Tester: take profit #5 a 1.2412 (1.2378 / 1.2382)
19:14:22 2004.02.27 11:10 Tester: take profit #5 a 1.2412 (1.2379 / 1.2383)
19:14:22 2004.02.27 11:11 Tester: take profit #5 a 1.2412 (1.2383 / 1.2387)
19:14:22 2004.02.27 11:12 Tester: take profit #5 a 1,2412 (1,2385 / 1,2389)
19:14:22 2004.02.27 11:13 Tester: take profit #5 a 1,2412 (1,2378 / 1,2382)
19:14:22 2004.02.27 11:14 Tester: take profit #5 a 1.2412 (1.2377 / 1.2381)
19:14:22 2004.02.27 11:15 Tester: take profit #5 a 1.2412 (1.2381 / 1.2385)
19:14:22 2004.02.27 11:16 Tester: take profit #5 a 1.2412 (1.2382 / 1.2386)
19:14:22 2004.02.27 11:17 Tester: take profit #5 a 1.2412 (1.2380 / 1.2384)
19:14:22 2004.02.27 11:18 Tester: take profit #5 a 1,2412 (1,2384 / 1,2388)
19:14:22 2004.02.27 11:19 Tester: take profit #5 a 1,2412 (1,2385 / 1,2389)
19:14:22 2004.02.27 11:20 Tester: take profit #5 a 1.2412 (1.2382 / 1.2386)
19:14:22 2004.02.27 11:21 Tester: take profit #5 a 1,2412 (1,2377 / 1,2381)
19:14:22 2004.02.27 11:22 Tester: take profit #5 a 1.2412 (1.2379 / 1.2383)
19:14:22 2004.02.27 11:23 Tester: take profit #5 a 1.2412 (1.2383 / 1.2387)
19:14:22 2004.02.27 11:24 Tester: take profit #5 a 1.2412 (1.2383 / 1.2387)
19:14:22 2004.02.27 11:25 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388)
19:14:22 2004.02.27 11:26 Tester: take profit #5 a 1.2412 (1.2387 / 1.2391)
19:14:22 2004.02.27 11:27 Tester: take profit #5 a 1.2412 (1.2386 / 1.2390)
19:14:22 2004.02.27 11:28 Tester: take profit #5 a 1,2412 (1,2384 / 1,2388)
19:14:22 2004.02.27 11:29 Tester: take profit #5 a 1.2412 (1.2385 / 1.2389)
19:14:22 2004.02.27 11:30 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388)
19:14:22 2004.02.27 11:31 Tester: take profit #5 a 1.2412 (1.2380 / 1.2384)
19:14:22 2004.02.27 11:32 Tester: take profit #5 a 1.2412 (1.2384 / 1.2388)
19:14:22 2004.02.27 11:33 Tester: take profit #5 a 1.2412 (1.2385 / 1.2389)
19:14:22 2004.02.27 11:34 Tester: take profit #5 a 1.2412 (1.2386 / 1.2390)
19:14:22 2004.02.27 11:35 Tester: take profit #5 a 1.2412 (1.2386 / 1.2390)
19:14:22 2004.02.27 11:36 Tester: take profit #5 a 1.2412 (1.2388 / 1.2392)
Allo stesso tempo è chiaro che i test non funzionano correttamente.
Questo non è per offendere gli sviluppatori, ma per il bene della causa - per far funzionare tutto correttamente il prima possibile.
Siamo solo per questo bene - per portare il tester a regime :)