Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
I'm on vaca so can't test this, but it looks to me like your fifth line of logic doesn't match your specification. Why are you multiplying by TickSize in the expression? If you're looking for a simple tick trend, then take off the "*TickSize" argument.
I also have one question about your spec: what do you want to see if the up or downslope is greater than one? You're only testing for a slope difference of exactly one.
Hi there Geoff - thank you for the reply, pls. see below
I suppose the reason to use TickSize was because that's what you can select via the Wizard interface. Perhaps it's also quicker if you want to apply this to any instrument rather than coding the tick increment by hand every time?
Anyway I have just amended the code by removing the TickSize and replacing it with + or - 0.01 (1 tick increment on CL) - the code works ok but the anomaly is still present, on exactly the same bar. In other words, I see no difference from the previous version of the strategy. I am a bit stumped.
Yes, you are right. I am not expecting to see anything in particular really - this is my very first attempt to use NinjaScript so I see this as more of an exercise in trying to understand its usefulness than anything else.
But I am puzzled as to why what I had expected to be a relatively simple code would sometimes not work.
I am curious as to why you are putting all this into a strategy and not an indicator ?
Also, make sure you have the following check at the top of your OnBarUpdate()
if (CurrentBar < 1) return;
I looked at your code logic, and was not able to figure out why that one bar in the example didn't have a marker on it. It has been reported some versions of UniRenko have a one tick inaccuracy in the high/low price of the tail of reversal candles. Meaning the highest high (or lowest low) tail is off by one tick. Looking at your chart example, the candle pattern in question meets this criteria, so you may have run into this bug.
Please can you clarify what you mean by 'Those are not equivalent expressions'?
Being a NinjaScript noob, I just found a YouTube video about alerts and it went via the strategy route. I didn't know better.
Please can you explain what this does?
I suspected it might be the case, but wouldn't the one-tick inaccuracy also show up in the data box (the one you get when you middle-click on a bar)? Whereas if I look at the data in there it checks out ok.
And of course that leads to the question: are you aware of which UniRenko bars may not have this bug?
I found 'Sim22_UniRenkoV1', for NT8 but Id like to know if anyone else has had success with loading and using it? Or if there is another download somewhere that I should use instead.
Thanks.