Incremental Order size +

This is an old and incomplete script that is being pulled up and dusted off as per request.

The sole purpose of this script was to provide code snippets allowing one to easily convert their own script/strategy to include incremental order sizes. More control over your pyramiding orders.

**It may repaint, and was not intended for trading but more as an attempt to provide examples for more control with pyramiding.
Jan 15
Informacje o Wersji: Updated to Pine version 4.
Usuń z Ulubionych Skryptów Dodaj do Ulubionych Skryptów


Thanks !!!! i was looking for how to solve my problem and after looking yyour code now its clear for me what i need to do. Thankss! You really helped me a lot
Adding to my reading list, thnx
CryptoRox syrinxflunki
@syrinxflunki, I hope you enjoy it.

It may look like a lot to read, but once you get into it, you'll see that most of it is simply cutting and pasting while changing some numbers.
+3 Odpowiedź
Very nice,
i have a script with similar structure in parts of the code.
Sometimes I want to run the script in version v4, but unfortunately I can't.

I think this line of code is the problem:
It causes problems when compiling in V4

last_long = long ? time : nz(last_long)
last_short = short ? time : nz(last_short)

Do you know a way to write your code in v4?
Can you encode the same function in v4 and share it as well?
Hello Samweis,

Thanks for the great question.

These variables refer to themselves. In the later versions of Pine, we need now need to use mutable variables and declare it something first.

last_long = 0
last_short = 0
last_long := long? time : nz(last_long)
last_short := short ? time : nz(last_short)

I hope that helps.

PS. Shame on me for notupdating tit o Version 4. Just published the update now.
+2 Odpowiedź
Samweis CryptoRox

Thanks for the update.

Ah, such a simple change. I should have thought of it myself ;)

So thanks again.
kind regards
Strona główna Skaner akcji Skaner Forex Skaner Krypto Kalendarz ekonomiczny Jak to działa Funkcje wykresów Cena Poleć przyjaciela Dobre Praktyki Centrum Pomocy Rozwiązania internetowe i brokerskie Widżety Wykresy Lekka Biblioteka Wykresów Blog i wiadomości Twitter
Profil Ustawienia profilu Konto i płatności Poleć przyjaciela