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
Help
Collapse
X
-
Help
How to plot values of an indicator to its normal ticksize? For example I want to plot the high value of EURUSD but my indicator will only plot up to 3 decimal places. How to plot the normal high value?Tags: None
-
Hello luxurious_04,
Thanks for your note.
To plot the high of your primary dataseries set the plot value to the value of the high dataseries with 0 bars ago.
For example:
in the Initialize() section:
Add(new Plot(Color.Blue, PlotStyle.Line, "myPlot"));
in the OnBarUpdate section:
Value.Set(High[0]);
This would create a line plot that connects the highs of the primary instrument.
Also, for example:
Value.Set(High[0] + 2 * TickSize);
This would create a line plot that connects the high plus 2 ticks of the primary instrument.
Below is a link to the help guide on the Value dataseries object.
http://www.ninjatrader.com/support/h.../nt7/value.htm
And also, here is a link to the help guide on TickSize.
http://www.ninjatrader.com/support/h...7/ticksize.htm
Please do not hesitate to contact us for any other NinjaTrader inquiries you may have.Chelsea B.NinjaTrader Customer Service
-
I tried that one but when the values plotted on the right side are being round to 2 decimal places. In the chart the high is 1.3093 and in my indicator the plotted dot values is 1.31 and I don't want that. I have used Values[0].Set(High[0]).
Comment
-
Hello luxurious_04,
To do my testing I am using the $EURUSD instrument.
With this instrument I have done prints to the output window showing that the High[0] is showing up to the 4th decimal place. (current high is 1.3014).
I then use Value.Set(High[0]) to set the plot to the high. The plot is currently showing at 1.3014.
This means that the High can contain more than 2 decimal places and the Plot is able to display it properly.
This instrument is showing the 10 thousands decimal place on the chart correct?
If you print the value of High[0] to the output window, does the print show the 10 thousands decimal place?
I look forward to your reply.Chelsea B.NinjaTrader Customer Service
Comment
-
Yes it prints 10 thousands decimal. I also printed out the plot value like this Print("Current High: +Value[0]"); and in the output window it prints thousands decimal but the indicator line that has the value is only 2 decimal places instead of 1.3096 it prints 1.31.
Comment
-
Hello luxurious_04,
Thanks for the reply.
May I have a screenshot of your chart along with the price printed in the output window from the same time?
To send a screenshot press Alt + PRINT SCREEN to take a screen shot of the selected window. Then go to Start--> Accessories--> Paint, and press CTRL + V to paste the image. Lastly, save as a jpeg file and add the file as an attachment.
For detailed instructions please visit the following link
http://take-a-screenshot.org/
I look forward to your response.Chelsea B.NinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by pickles1774, 02-28-2024, 12:34 PM
|
2 responses
32 views
0 likes
|
Last Post
by pickles1774
Today, 05:25 AM
|
||
Started by Allwest, Yesterday, 10:25 PM
|
2 responses
19 views
0 likes
|
Last Post Today, 04:18 AM | ||
Started by bmandonlidal, Today, 03:34 AM
|
0 responses
1 view
0 likes
|
Last Post
by bmandonlidal
Today, 03:34 AM
|
||
Started by LincolnOrtiz, Today, 03:10 AM
|
0 responses
2 views
0 likes
|
Last Post
by LincolnOrtiz
Today, 03:10 AM
|
||
Started by Dr Kerry, Today, 02:03 AM
|
0 responses
4 views
0 likes
|
Last Post
by Dr Kerry
Today, 02:03 AM
|
Comment