Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy Builder - Realized PnL question

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

    Strategy Builder - Realized PnL question

    I'm using the Strategy Builder to create a script and i'm testing it in Playback mode with Historical data. As the script runs i want to keep track of my Realized PnL. Should the realized PnL go below a certain level the stategy should stop trading.

    The problem i'm having is that before an actual trade has happened there is already a Realised PnL value. This appears to be based on hypothetical trades that could have occured before the strategy was actually enabled.

    Because of this preexisting value i am unable to establish what the "real" PnL from actual trades is.
    Any ideas, suggestions or advice?
    Thanks

    #2
    Hello cupir2,

    When you apply a strategy it runs a backtest initially so it will start with some trades in the performance. Depending on when you start playback you may be able to isolate the current trades. Most commonly you would use the session to reset the pnl variable so you know the session pnl, there is a sample of that concept here.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by NullPointStrategies, Yesterday, 05:17 AM
    0 responses
    62 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    134 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    75 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    45 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    50 views
    0 likes
    Last Post TheRealMorford  
    Working...
    X