![]() |
This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com
|
|||||||
| Indicator Development Support for the development of custom indicators using NinjaScript. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Junior Member
Join Date: Sep 2007
Posts: 6
Thanks: 0
Thanked 0 times in 0 posts
|
I developed an indicator and compiled it sucessfully but i cannot see it in the indicators menu of the plotted chart
|
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: May 2008
Location: Denver, CO
Posts: 3,157
Thanks: 0
Thanked 3 times in 3 posts
|
Hello,
You see all of the other indicators though? Try posting the indicator and I will test it on my end.
Ben
NinjaTrader Customer Service |
|
|
|
|
|
#3 |
|
Junior Member
Join Date: Sep 2007
Posts: 6
Thanks: 0
Thanked 0 times in 0 posts
|
protectedoverridevoid Initialize() { Add(new Plot(Color.FromKnownColor(KnownColor.Orange), PlotStyle.Line, "Zobv1")); Add(new Plot(Color.FromKnownColor(KnownColor.Green), PlotStyle.Line, "Zobv9")); Add(new Plot(Color.FromKnownColor(KnownColor.DarkViolet), PlotStyle.Line, "Zobv21")); CalculateOnBarClose = true; Overlay = false; PriceTypeSupported = false; } ///<summary> /// Called on each bar update event (incoming tick) ///</summary> protectedoverridevoid OnBarUpdate() { // Use this method for calculating your indicator values. Assign a value to each // plot below by replacing 'Close[0]' with your own formula.\ double Obv1=OBV()[0]; Zobv1.Set(Obv1); Obv9=EMA(OBV(),9)[0]; Zobv9.Set(Obv9); Obv21=EMA(OBV(),21)[0]; Zobv21.Set(Obv21); } |
|
|
|
|
|
#4 |
|
NinjaTrader Customer Service
Join Date: May 2008
Location: Denver, CO
Posts: 3,157
Thanks: 0
Thanked 3 times in 3 posts
|
Hello,
Try putting if(CurrentBar < 22) return; right after OnBarUpDate(). This link will help understand why: http://www.ninjatrader-support2.com/...ead.php?t=3170 If that does not work, let me know.
Ben
NinjaTrader Customer Service |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Moving indicators on the chart | unclelou | Charting | 2 | 01-27-2009 05:25 PM |
| Indicator not in indicators list on chart. | CraigC | Indicator Development | 3 | 06-17-2008 09:29 PM |
| FR: 'Open Chart' command in the Right-Click Context Menu | Elliott Wave | Market Analyzer | 3 | 05-05-2008 08:58 AM |
| This is how the indicator menu should work... | Elliott Wave | Suggestions And Feedback | 1 | 04-29-2008 09:52 PM |
| Drawing on Chart Indicators? | ashish | Historical NinjaTrader 6.5 Beta Threads | 6 | 11-10-2007 11:59 PM |