NinjaTrader Support Forum  
X

Attention!

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


Go Back   NinjaTrader Support Forum > NinjaScript Development Support > Indicator Development

Indicator Development Support for the development of custom indicators using NinjaScript.

Reply
 
Thread Tools Display Modes
Old 03-27-2009, 01:32 PM   #1
badasan
Member
 
Join Date: Feb 2009
Posts: 44
Thanks: 0
Thanked 0 times in 0 posts
Default Calling an existing indicator

Can I call existing standard indicator in the new indicator I try to write?
Here is what I want to do and want to know if it can be done.

I want to plot an upper band and lower band to each bar by adding
ATR (average true range, which is standard ninja indicator) to high of the bar
to create an upper band and by subtracting ATR to the low of the bar
to create a lower band.

Question is that can I just simply call standard ATR indicator in new indicator or do I have to write ATR function in my code? If I can call, could you show
me an example?

Thanks.
Don
badasan is offline  
Reply With Quote
Old 03-27-2009, 01:39 PM   #2
NinjaTrader_Josh
NinjaTrader Product Manager
 
NinjaTrader_Josh's Avatar
 
Join Date: May 2007
Location: Denver, CO
Posts: 17,458
Thanks: 1
Thanked 106 times in 70 posts
Default

Don,

You can call the ATR indicator in your new indicator. Please see an example here: http://www.ninjatrader-support.com/HelpGuideV6/ATR.html
NinjaTrader_Josh is offline  
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Strategy calling Indicator gg80108 Strategy Development 3 03-16-2009 02:32 PM
Calling terms from another indicator Insearch General Programming 7 02-24-2009 03:33 PM
Tweak an existing indicator unclelou Indicator Development 7 10-16-2008 10:36 AM
altering existing indicator jake28787 Indicator Development 1 03-26-2008 06:19 AM
Strategy calling Indicator Error GuyFB Strategy Analyzer 7 12-13-2007 10:28 AM


All times are GMT -6. The time now is 05:06 AM.