NinjaTrader Support Forum  

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 04-01-2012, 11:06 AM   #1
jimdog42
Junior Member
 
Join Date: Jun 2011
Location: denver
Posts: 8
Thanks: 0
Thanked 0 times in 0 posts
Default Need help with Risk To Reward

Greetings,

I was wondering if one of you Zen Master Code writers could help me with a SUPER simple thing. I've modified the Risk to Reward Indicator, and it almost does what I want, but not quite. I'm certain the modification needed is simple. The R/R indicator has three lines showing the entry exit and stop, and shows what the R/R is, I've added the actual dollar amount to what the risk is, BUT I don't know how to automatically get the price data for each security I'm trading. I now have it hard coded so obviously it only works for instruments with the same price per tick, but would very much like for this data to get passed along automatically.

Would anyone like to help me and add this in or at least tell me what the variables are so I can try it myself?

I would appreciate it.

JimDog
jimdog42 is offline  
Reply With Quote
Old 04-01-2012, 06:40 PM   #2
NinjaTrader_AdamP
NinjaTrader Customer Service
 
NinjaTrader_AdamP's Avatar
 
Join Date: Aug 2011
Location: Denver, CO, USA
Posts: 2,895
Thanks: 241
Thanked 375 times in 365 posts
Default

jimdog,

Please see the following indicator.

http://www.ninjatrader.com/support/f...catid=4&id=367

It adds a dataseries using the name/type/period.

Are you trying to add dataseries on the fly or use them chart by chart?
NinjaTrader_AdamP is offline  
Reply With Quote
Old 04-01-2012, 06:53 PM   #3
jimdog42
Junior Member
 
Join Date: Jun 2011
Location: denver
Posts: 8
Thanks: 0
Thanked 0 times in 0 posts
Default

Ah! I already have that indicator in my "tool bag", good tip. The variable I needed was:

Instrument.MasterInstrument.PointValue

from here I was able to get things working as I wanted. I just drag my entry and stop lines and it shows me the dollar amount of risk automatically regardless of the instrument. Very surprised this hasn't been done already.

Thanks for the follow up!

Jim
jimdog42 is offline  
Reply With Quote
Reply

Tags
risk, risk reward, trade management

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
Risk/Reward indicator. Drakmyre Indicator Development 4 01-29-2013 09:03 AM
Risk/ Reward Calculator pedroprada@bellsouth.net Indicator Development 4 10-21-2012 03:54 PM
Help, Risk Management Italy General Programming 1 06-15-2010 04:24 AM
Risk to Reward or R/R results.................. Angel Suggestions And Feedback 1 05-17-2007 12:15 PM
Risk constraints QQQ Suggestions And Feedback 1 03-30-2005 02:56 PM


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