• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Calculating the Value of a Position

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Calculating the Value of a Position

    Suppose I'm Trading /ES. I want to calculate the value of my position at any point throughout the trading day. If I have 1 contract and I'm up 1 pt when I look, and I know that /ES has a value of $50 per point, I know that I'm up $50. My question is if i wanted to write a script to do this automatically, how do I represent the $50 per point in ninjascript? Would it be something like the PerformanceUnit.Currency? Any help would be greatly appreciated.

    D
    Last edited by dmking; 03-24-2019, 06:16 PM.

    #2
    Hello dmking,

    The PointValue for an instrument can be found through the Instrument.MasterInstrument properties.

    Below is a public link to the help guide.
    https://ninjatrader.com/support/help...pointvalue.htm
    Chelsea B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by ralett, Today, 11:28 AM
    0 responses
    1 view
    0 likes
    Last Post ralett
    by ralett
     
    Started by ChazJ, Today, 09:59 AM
    1 response
    4 views
    0 likes
    Last Post NinjaTrader_Jesse  
    Started by Irukandji, Today, 09:34 AM
    1 response
    3 views
    0 likes
    Last Post NinjaTrader_PatrickG  
    Started by lunardiplomacy, Today, 08:32 AM
    3 responses
    12 views
    0 likes
    Last Post NinjaTrader_PatrickG  
    Started by ralett, Today, 08:24 AM
    1 response
    11 views
    0 likes
    Last Post NinjaTrader_PatrickG  
    Working...
    X