Rewrite SwingTeller code from binck ProTrader to Prorealtime code
Forums › ProRealTime English forum › ProOrder support › Rewrite SwingTeller code from binck ProTrader to Prorealtime code
- This topic has 66 replies, 6 voices, and was last updated 7 years ago by AVT.
-
-
04/05/2017 at 2:24 PM #3113104/05/2017 at 2:35 PM #3113404/05/2017 at 3:27 PM #31137
Drawn variables as text can’t be rounded with no digit.. So I assume I need to type 9 times*2 in the code to avoid the .0 digits .. argh 🙂
I’m going first to make it “live”, understand counting in real time and not draw the 9th count once when its finish already.
In the meantime, could you please explain us a bit how to you use this indicator and what it is so ‘useful’ to you? Once it will be finished, I’ll add it to the library and I’d like to add explanations for it. Thanks.
04/05/2017 at 4:50 PM #31142Fantastic!
Well, it is called a swingcounter and it’s main job is to signal a reversal.
when a full swing +9 or -9 has appeared the chances of an upcoming bottom or a top increases a lot. A fully upswing +9 combined with a red 10th candle suggest to exit your long position. Its the same for a downswing -9 combined with a 10th green candle means exit your short position.
This indicator combined with the bollingerbands RSI works fantastic!
04/05/2017 at 6:26 PM #31147Thanks joerie1,
This indicator combined with the bollingerbands RSI works fantastic!
do you have any example how to combine the count with the BollingerBands RSI?
04/05/2017 at 6:31 PM #3114804/05/2017 at 6:39 PM #3115404/05/2017 at 6:40 PM #31155Haha sorry thought you were the other guy, lol
Yes I can show you!
Look at the image I attache to this message. It is a 1 hour chart of the S&P at this moment. You will see that the swing 9 has almost completed. The RSI is now on overbought. When a red hour candle appears its time to exit your long position!
04/05/2017 at 6:46 PM #3115804/05/2017 at 7:34 PM #31160Hi Joeri,
Yeah i see it The RSI does correspond with Nico’s Dynamic RSI or not ?
The code i use for the dybanic RSI is this
1234567891011121314151617181920212223242526272829303132333435rem Dynamische RSIperiodmoy=50periodeRSI=12coeff=2monrsi=RSI[periodeRSI](close)ind = SQUARE(monrsi)ind1 = Average[periodmoy](monrsi)ind2 = Average[periodmoy](ind)variance = ind2 - SQUARE(ind1)ecart = SQRT(variance)UpBand = ind1 + coeff*ecartDownBand = ind1 - coeff*ecartUP = 100Middle = 50Down = 0RSI70 = 70RSI30 = 30a = downbandb = middlecross1 = 0cross2 = 0// Golden Cross detectionIF a CROSSES OVER b THENcross1 = 50ENDIF// Death Cross detectionIF a CROSSES UNDER b THENcross2 = 50ENDIFRETURN monrsi AS "RSI", UpBand COLOURED (0, 255, 0) AS "UpBand", DownBand COLOURED (255, 0, 0) AS "DownBand" , Middle,UP,Down,RSI70,RSI30 , cross1 COLOURED (255, 0, 0) , cross2 COLOURED (0, 255, 0)Maybe it helps.
To Nicolas,
I hope you can make it work for the swingcounter to start with showing 1
If only at the end of a full swing of 9 would be shown it will be to late to respond to it
System i use is for a swing to start with 1 and confirmid the next day with a 2 i step in and (hopefully ) it will last a full swing to 9.
Im sorry if some things would mean for you to do a lot of coding but trust me it will be greatly appriciated !!
If i can do something on that part please let me know i would be more then willing to do the shit stuff for you 🙂
Maybe i sound greedy now 🙂 but it would be awesome if its possible to make a screener next to the indicator that shows all the stocks, or whatever, that has the start of a swing 1 up or 1 down. Then i think the swingcounter would be complete and very easy to use on a daily basis or any timeframe ofcource.
Thank and i mean MANY thanks !!
rgds
John
04/05/2017 at 7:48 PM #3116204/05/2017 at 8:23 PM #3116604/05/2017 at 9:04 PM #31170I’m afraid it’s not possible to make the counter appearing in real time and erase the already numbers drawn on chart. Probuilder don’t allow to erase graphical objects already drawn and because we cannot change variables arrays..
This is something I’m often stuck with, but I thought I could do something for this indicator though.. I’ll try another idea tomorrow.
04/05/2017 at 9:29 PM #31171Hey Nicolas,
You can make it happen for the swing to start with 1 and appear on the chart are you?
Maybe as an alternative you can do this :
If a swing count starts and fails at, lets say, day 5 you put something like “Fail” or “Swingend” or some other stop sign.. That way you dont have to erase anything.
Would maybe even better, we are more able to check how many time a swing fails and how many times it goes the full length.
for the rest ill leave it up to you to find any better solution but i can imagine its hard if things cant be erased anymore
rgds
John
04/06/2017 at 7:37 AM #31188Yes, delete previous counting would mean not to draw them at all, and since we don’t know what will happen in the next candlestick, it’s not possible..
I would ask this morning how you’d like the false counting to be displayed and you already answered it with the “fail” text idea. That’s ok to do it like this I think.
About the screener, it’s already possible to make it, but does it needs to have any RSI condition in it?
-
AuthorPosts
Find exclusive trading pro-tools on