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)
Trading is not like playing with slot machines. The question how to enter or exit a position when "the color changes" is not very professional. Also you should not try to access color objects in NinjaTrader, but rahter access the underlying condition.
A color change of a Heikin Ashi bar may signal a change in the underlying trend. Now you did not specify which version of the Heikin Ashi bars you intend to use. Let me assume that you use standard NinjaTrader Heikin Ashi bars. In that case there are 3 different color states
- upclose: close > open
- downclose: close < open
- doji: close = open
You can check for these conditions via the strategy builder.
I have coded an enhanced version of the HeikinAshi indicator, which you can find here:
The indicator has the trend (uptrend or downtrend) exposed as a BoolSeries. You can access this BoolSeries directly via code. However, the strategy builder cannot access the BoolSeries, but would require a DataSeries object instead.
I do have a modified version which has the BoolSeries replaced with a DataSeries. The DataSeries can hold the value + 1 (for uptrend) and - 1 (for downtrend), and it can be directly accessed via the strategy builder. So all you would need to do is to check for a change of that value. Please let me know, if you wish to use the modified version of the indicator, and I will post it.
Thank you for replying to my question. Indeed i might not come across professional just because i am not professional.
I am also very rusty on my C++, C# is new. So therefor i can only appreciate your reply even more, thank you.
Also thank you for the indicator to download and the tip on the BoolSeries, i will try them both.
Thank you for your reply and information. I very much appreciate that you have taken the time to educate me and to show how it would be written. Indeed i am using ninjatrader, sorry to mention that. Your clarification is very educational and can't wait to try to implement it. Thank you!
heikin ashi close = average of high low close open of current standard candlestick bar or hi low open close bar
heikin ashi open = average of close and open of last heikin ashi bar
so the heiken ashi close value depends on what just happened in the current period
and the heikin ashi open value depends of what happened on the last period.
Thus a heikin ashi bar is not dependent on the future period?? In short, it is not cheating. Reason I asked, is I had a spread sheet formula that showed a fantastic profit loss result. What happened was I was using the current hi low values to put a position on at the open.
Hell, then why not sell at the high and buy at the low since I knew at the open what the high and low was going to be?