Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Account Cash Value/GetAccountValue Seems High

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

    Account Cash Value/GetAccountValue Seems High

    I'm using the simulator to backtest a strategy. I've noticed that the cash value is much higher than what it should be.

    For example, one month I started with $2000 as my cash value and realized $1653.59. However, GetAccountValue returned (and the cash value on the Accounts tab showed) $6323.26. The Realized value on the Accounts tab is correct.

    This is baffling because I'm not doing anything to manipulate the cash value. I'm just using EnterLong and EnterShort as normal.

    I did switch to ExitLongLimit/ExitShortLimit from SetProfitTarget around when I noticed this happening. Could that be the problem? Is there another setting that I should check? Thanks for your feedback.

    #2
    Hello micprice,

    Thank you for your inquiry.

    I am a bit unclear of what you are doing. If you are running a backtest on a strategy, this will not affect your account outside of the backtest. The Accounts tab on the NinjaTrader Control Center shows your current account information. GetAccountValue will return that information about the account the strategy is running on, hence why both values match.

    Once your strategy starts making live trades, then the account will be affected.
    Zachary G.NinjaTrader Customer Service

    Comment


      #3
      I'm actually using a simulation account, with the initial value set to $2000. The value of the simulation account has always kept in step with what was being realized. Lately, it hasn't and it's not clear why.

      I'm suspecting it's safest to just calculate the account value myself based upon the starting value, and what the strategy realizes through trading. This may also help avoid any syncing issues when I go live. Well, have a great holiday!

      Comment


        #4
        Hello micprice,

        The same would apply if you are using a simulation account. A backtest does not take any account into account when doing trades; all it is doing is testing the performance of a particular strategy over a period of time you specify.

        The account will only be affected when a strategy is active on an account and is performing trades in real time.

        Have a great holiday!
        Zachary G.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        640 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        366 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        107 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        569 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        572 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X