Price information from the Current Bar needs to be plotted on the screen now but at a point on the chart 26 periods from now. Any thoughts on how to make this work?
Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Plotting the Future
Collapse
X
-
Plotting the Future
I am working on Ichimoku indicators, and one of the features of Ichimoku is it uses current price action to plot future support and resistance.
Price information from the Current Bar needs to be plotted on the screen now but at a point on the chart 26 periods from now. Any thoughts on how to make this work?Tags: None
-
Originally posted by Grasul View PostI am working on Ichimoku indicators, and one of the features of Ichimoku is it uses current price action to plot future support and resistance.
Price information from the Current Bar needs to be plotted on the screen now but at a point on the chart 26 periods from now. Any thoughts on how to make this work?
This has been solved. Use the Ichi in post 29 of the below thread.... its open code so you can see how its done.
Comment
-
The calculations of the indicator you linked have an error in them I believe.
The correct calculation for Tenkan Sen is (Highest High + Lowest Low) / 2 for the last 9 (default) bars.
The calculation the indicator is using is:
TenkanSen.Set((MAX(Fast)[0] + MIN(Fast)[0])* 0.5);
which translates to (Highest Close + Lowest Close) / 2 which of course is not the same thing.
The correct calculation for Tenkan Sen is:
TenkanSen.Set((MAX(High, Fast)[0] + MIN(Low, Fast)[0])* 0.5);
The Kijun Sen calculation and Senkou Span B have the same error but are both also easily fixed.Last edited by Grasul; 11-28-2011, 07:25 PM.
Comment
-
I have not looked at the code in the indicator, but it would not surprise me to find that you are exactly correct... it looks so from your snippets. I often find such discrepencies in shared indicators and make a habit, as you have apparently done with this one, of checking line for line shared indicator I rely on for actual trade signals.
I use Ichi just as a quick snap shot overview of a market I haven't been following. I find it has too much lag to be of use for actual trade signals. Thanks for pointing out the descrepencies. I have not put it into the indicator section because it is not my indicator. Maybe someone who uses Ichi will take the time to refactor the code I posted, make it conform exactly to the classic Ichi rules, then post it into the indicator section. I can't see having that time myself, but if no one does it, perhaps I will someday.
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by helpwanted, Today, 03:06 AM
|
1 response
7 views
0 likes
|
Last Post Today, 03:35 AM | ||
Started by Brevo, Today, 01:45 AM
|
0 responses
7 views
0 likes
|
Last Post
by Brevo
Today, 01:45 AM
|
||
Started by aussugardefender, Today, 01:07 AM
|
0 responses
5 views
0 likes
|
Last Post Today, 01:07 AM | ||
Started by pvincent, 06-23-2022, 12:53 PM
|
14 responses
242 views
0 likes
|
Last Post
by Nyman
Today, 12:47 AM
|
||
Started by TraderG23, 12-08-2023, 07:56 AM
|
9 responses
384 views
1 like
|
Last Post
by Gavini
Today, 12:29 AM
|
Comment