Traduzione codice TW Zig Zag invincible
Forums › ProRealTime forum Italiano › Supporto ProBuilder › Traduzione codice TW Zig Zag invincible
- This topic has 5 replies, 4 voices, and was last updated 1 week ago by Renero.
Viewing 6 posts - 1 through 6 (of 6 total)
-
-
12/03/2024 at 11:53 AM #241033
Buongiorno,
chiedo cortese traduzione del seguente codice.
Grazie per l’aiuto.
https://www.tradingview.com/script/zdjIB3Bh-Zigzag3-Invincible3/
12/03/2024 at 3:44 PM #241036Ecco qui:
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495//------------------------------------////PRC_ZigZag and SR//version = 0//03.12.2024//Iván González @ www.prorealcode.com//Sharing ProRealTime knowledge//------------------------------------//// Inputs//------------------------------------//prd=18showSR=1 //Show Support and Resistance//Boolean// 0 means false 1 means TrueshowLabels=1 //Boolean// 0 means false 1 means TrueshowZZ=1 //Boolean// 0 means false 1 means True//------------------------------------//// Calculate Pivot High and Low//------------------------------------//ph = high=highest[prd](high)pl = low=lowest[prd](low)//------------------------------------//// Calculate Direction//------------------------------------//if ph and pl=0 thendir=1elsif pl and ph=0 thendir=-1elsedir=direndifdirchanged=dir<>dir[1]//------------------------------------//// Calculate ZizZag levels and x//------------------------------------//if ph or pl thenif dirchanged thenif dir=1 then$zigzag[t+1]=highest[prd](high)$zigzagidx[t+1]=barindex$dir[t+1]=1t=t+1elsif dir=-1 then$zigzag[t+1]=lowest[prd](low)$zigzagidx[t+1]=barindex$dir[t+1]=-1t=t+1endifelseif dir=1 and highest[prd](high)> $zigzag[t] then$zigzag[t]=highest[prd](high)$zigzagidx[t]=barindexelsif dir=-1 and lowest[prd](low)< $zigzag[t] then$zigzag[t]=lowest[prd](low)$zigzagidx[t]=barindexendifendifendif//------------------------------------//// Draw ZigZag and Levels//------------------------------------//$zigzag[0]=undefined$zigzagidx[0]=undefinedif islastbarupdate thenif showZZ then//Last ZigZagdrawsegment($zigzagidx[max(0,t-1)],$zigzag[max(0,t-1)],$zigzagidx[t],$zigzag[t])endifif showSR and $dir[t]=1 thendrawsegment($zigzagidx[t],$zigzag[t],barindex,$zigzag[t])style(dottedline,3)coloured("green")drawsegment($zigzagidx[max(0,t-1)],$zigzag[max(0,t-1)],barindex,$zigzag[max(0,t-1)])style(dottedline,3)coloured("red")elsif showSR and $dir[t]=-1 thendrawsegment($zigzagidx[t],$zigzag[t],barindex,$zigzag[t])style(dottedline,3)coloured("red")drawsegment($zigzagidx[max(0,t-1)],$zigzag[max(0,t-1)],barindex,$zigzag[max(0,t-1)])style(dottedline,3)coloured("green")endifif showLabels thendrawpoint($zigzagidx[max(0,t-1)],$zigzag[max(0,t-1)],2)coloured("blue",100)drawpoint($zigzagidx[t],$zigzag[t],2)coloured("blue",100)endif//Draw all ZigZagfor i=t-1 downto 1 doif showZZ thendrawsegment($zigzagidx[max(0,i-1)],$zigzag[max(0,i-1)],$zigzagidx[i],$zigzag[i])endifif showSR and $dir[i]=1 thendrawsegment($zigzagidx[i],$zigzag[i],$zigzagidx[i+1],$zigzag[i])style(dottedline,3)coloured("green")drawsegment($zigzagidx[max(0,i-1)],$zigzag[max(0,i-1)],$zigzagidx[i],$zigzag[max(0,i-1)])style(dottedline,3)coloured("red")elsif showSR and $dir[i]=-1 thendrawsegment($zigzagidx[i],$zigzag[i],$zigzagidx[i+1],$zigzag[i])style(dottedline,3)coloured("red")drawsegment($zigzagidx[max(0,i-1)],$zigzag[max(0,i-1)],$zigzagidx[i],$zigzag[max(0,i-1)])style(dottedline,3)coloured("green")endifif showLabels thendrawpoint($zigzagidx[i],$zigzag[i],2)coloured("blue",100)endifnextendif//------------------------------------//return12/03/2024 at 3:51 PM #24103812/04/2024 at 6:21 PM #24111012/04/2024 at 8:11 PM #241122Probabilmente non l’hai copiato tra gli indicatori.
Dalla foto mi sembra che tu l’abbia messo erroneamente tra le strategie.
1 user thanked author for this post.
12/05/2024 at 8:39 AM #241130Probabilmente non l’hai copiato tra gli indicatori.
Dalla foto mi sembra che tu l’abbia messo erroneamente tra le strategie.
Eh si proprio così errore mio.
Grazie e buona giornata
-
AuthorPosts
Viewing 6 posts - 1 through 6 (of 6 total)
Find exclusive trading pro-tools on
Similar topics: