• 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

Total unrealized P&L Market Analyser or any were

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

    Total unrealized P&L Market Analyser or any were

    How to make visible total unrealized P&L on total account position with different instruments? Any suggestion welcome.

    #2
    Hello condor,

    Thanks for opening the thread.

    Outside the context of a strategy, if you would like to get the Account's Unrealized PnL, you can subscribe to AccountItemUpdate.

    If you would like to get information about positions of an Account, including the Unrealized PnL, you will want to subscribe to PositionUpdate.

    AccountItemUpdate - https://ninjatrader.com/support/help...itemupdate.htm

    PositionUpdate - https://ninjatrader.com/support/help...tionupdate.htm

    Sample code is included in the help documentation. If you want to reference a complete working example, I would advise to look for the relevant sections in the Sample AddOn Framework example. You can find the relevant code in the AddOn by searching for "AccountItemUpdate" and "PositionUpdate."

    The AddOnFramework example can be found here: https://ninjatrader.com/support/help...t_overview.htm

    For placing in the Market Analyzer, you can create an indicator that does these calculations and places the values in a Plot, or you can create a Market Analyzer Column and have it update the CurrentValue for that column.

    The included Market Analyzer columns in NinjaTrader 8 contain source code that you can reference, as well.

    Please let me know if I may be of further assistance.
    Last edited by NinjaTrader_Jim; 07-21-2017, 02:37 PM.
    JimNinjaTrader Customer Service

    Comment


      #3
      Unfortunately, I am not C# programmer. Appreciate for any help.

      Comment


        #4
        If you would like to hire a consultant to write this code for you, I can have a member of our Business Development team reach out to you with a list of NinjaScript Consultants who would be happy to do so.

        If that is the case, please write in to platformsupport[at]ninjatrader[dot]com with the text "Attention Jim" and the thread URL.
        JimNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Jschmelz, Today, 01:13 PM
        0 responses
        5 views
        0 likes
        Last Post Jschmelz  
        Started by Newtrader101, Today, 12:37 PM
        0 responses
        5 views
        0 likes
        Last Post Newtrader101  
        Started by shishir_nse, Today, 11:13 AM
        0 responses
        6 views
        0 likes
        Last Post shishir_nse  
        Started by shishir_nse, Today, 11:02 AM
        0 responses
        3 views
        0 likes
        Last Post shishir_nse  
        Started by 12VMan, Today, 07:15 AM
        3 responses
        18 views
        0 likes
        Last Post Lancer
        by Lancer
         
        Working...
        X