NinjaTrader Support Forum  
X

Attention!

This website will be down for maintenance from Friday May 24th at 6PM MDT until Sunday May 26th at 12PM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com


Go Back   NinjaTrader Support Forum > NinjaScript File Sharing > NinjaScript File Sharing Discussion

NinjaScript File Sharing Discussion Discussion for shared NinjaScript files.

Reply
 
Thread Tools Display Modes
Old 11-05-2009, 09:10 PM   #1
suprsnipes
Senior Member
 
Join Date: Aug 2008
Posts: 233
Thanks: 19
Thanked 5 times in 5 posts
Default Please help me with this basic indicator

Hi,

I need an idea of how to create a very basic indicator. All I want to do is take the session open (very similar to the CurrentDayOHLC NT indicator) and subtract it by 20pts and display this value on the chart in the same manner.

I have never used NinjaScript before, apart from the tutorials, but I am still struggling to understand how to do the above.

Any help will be greatly appreciated, I am a fully licensed user by the way.

Thank you in advance
suprsnipes is offline  
Reply With Quote
Old 11-06-2009, 05:40 AM   #2
NinjaTrader_Bertrand
NinjaTrader Customer Service
 
NinjaTrader_Bertrand's Avatar
 
Join Date: Sep 2008
Location: Germany
Posts: 22,421
Thanks: 252
Thanked 982 times in 964 posts
Default

suprsnipes, please try something like this to get this value with 20 tick offset -

Code:
 
double myOffsetOpen = CurrentDayOHL().CurrentOpen[0] - 20 * TickSize;
NinjaTrader_Bertrand 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
Can anyone help add a .wav file for alerts to this basic indicator bigmama General Programming 9 10-31-2009 12:33 AM
Basic code blaircampbell General Programming 1 05-26-2009 07:12 AM
Basic Issues poeds Miscellaneous Support 10 09-02-2008 08:00 AM
Basic Issues poeds Miscellaneous Support 0 08-30-2008 08:18 AM
Basic help for non-progammer alfie Automated Trading 2 12-26-2007 06:24 AM


All times are GMT -6. The time now is 11:19 PM.