![]() |
|
|||||||
| Indicator Development Support for the development of custom indicators using NinjaScript. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Junior Member
Join Date: Oct 2008
Posts: 14
Thanks: 0
Thanked 0 times in 0 posts
|
Hello,
Can someone help me with setting up an indicator to do the following. -Plot 2 horizontal lines - both an overnight high and overnight low (in between market close and open) -Plot 2 horizontal lines - first hour high and a first hour low (first hour the market is open) -Plot two more Horizontal user defined lines. Any help would greatly be appreciated. |
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: May 2008
Location: Denver, CO
Posts: 3,157
Thanks: 0
Thanked 3 times in 3 posts
|
Hello,
I recommend giving it a try in our strategy wizard: http://www.ninjatrader-support.com/H...verview41.html If you get stuck provide us with a screen shot of your set up and we will assist.
Ben
NinjaTrader Customer Service |
|
|
|
|
|
#3 |
|
Junior Member
Join Date: Oct 2008
Posts: 14
Thanks: 0
Thanked 0 times in 0 posts
|
Am I looking for a strategy or indicator?
|
|
|
|
|
|
#4 |
|
NinjaTrader Customer Service
Join Date: May 2008
Location: Denver, CO
Posts: 3,157
Thanks: 0
Thanked 3 times in 3 posts
|
Hello,
You will need to build this as a strategy, but instead of orders you will use drawings. I recommend going through the tutorials first.
Ben
NinjaTrader Customer Service |
|
|
|
|
|
#5 |
|
Junior Member
Join Date: Oct 2008
Posts: 14
Thanks: 0
Thanked 0 times in 0 posts
|
So this is my attempt at drawing the high between 630 and 730pst. How would I adjust this so that only 1 line is drawn for that time period.
|
|
|
|
|
|
#6 |
|
NinjaTrader Product Manager
Join Date: May 2007
Location: Denver, CO
Posts: 17,458
Thanks: 1
Thanked 106 times in 70 posts
|
You may need to unlock your code and change the signal name of the horizontal line. You don't want it to be a unique name. You just want one line that updates so you want to pass in one name.
DrawHorizontalLine("My horizontal line", High[0], Color.Blue); Notice the removal of the + CurrentBar part.
Josh
NinjaTrader Customer Service |
|
|
|
|
|
#7 |
|
Junior Member
Join Date: Oct 2008
Posts: 2
Thanks: 0
Thanked 0 times in 0 posts
|
I am trying to do a similar thing, I want lines to be drawn for entries and exits on my strategy. I have attached a sample from esignal -
Problem - How to draw a horizontal line that continues until price crosses it. In NT Indicator - When you draw Horizontal Line, the line only lasts for that specific tick/bar - and you have to draw it again for subsequent bars. This poses the problem, when you are using the same name for the bar in a loop etc. Is this even possible on an indicator, or do you have to use a strategy to accomplish this. Thanks in advance. Simon |
|
|
|
|
|
#8 |
|
NinjaTrader Product Manager
Join Date: May 2007
Location: Denver, CO
Posts: 17,458
Thanks: 1
Thanked 106 times in 70 posts
|
gaatr,
It is possible. I suggest you just use a plot with a style of dash. Then just set the plot to take the value you want for each bar. If you keep setting it to the same value it will end up drawing a horizontal line segment. Alternatively you may want to use DrawLine() or any of the other draw methods available to you. Play around with it. See what works for you. You do not need a strategy to do chart plotting.
Josh
NinjaTrader Customer Service |
|
|
|
|
|
#9 |
|
Junior Member
Join Date: Oct 2008
Posts: 2
Thanks: 0
Thanked 0 times in 0 posts
|
Thanks Josh. I will play around with it, thanks for the quick response.
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Displaying the label for horizontal plot lines | mgbloomfield | Indicator Development | 12 | 09-20-2009 02:59 PM |
| ADX Lines | pivot44 | Miscellaneous Support | 1 | 05-14-2008 03:03 PM |
| Saving Drawn Lines and Fib Lines | jfalbert19 | Charting | 6 | 04-01-2008 07:45 PM |
| Sma To Plot Color Bars Not Lines | avlasov | Indicator Development | 4 | 12-08-2007 03:37 PM |
| more lines in the DOM | jeff1 | Suggestions And Feedback | 4 | 10-21-2006 02:20 PM |