Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strat builder and resetting profit.

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

    Strat builder and resetting profit.

    Hello all you beautiful Ninjas I have an issue that I am hoping someone has the answer to. I am looking to throw a strategy I have through the analyzer. Currently I change the date every run so the PandL start over but would like to be able to add something in the builder that would keep track of the P&L and then reset it every day at midnight for the next day. Doing this manually is starting to try my patience. Any help would be amazing, thanks in advance.


    #2
    Hello sprks7979,

    Thank you for your post.

    Tracking the daily PnL in the Strategy Builder is tricky due to limitations on how variables are assigned. My colleague has created an example, DailyLossLimitBuilderExample_NT8 at the link below, that keeps track of the strategy's overall PnL and the PnL at the end of the previous session each in a custom series. It can then keep track of the DailyPNL variable by subtracting value of YesterdaysPNL[0] from StrategyTotalPNL[0]. Here is the link to his post which has the example attached:

    Hello, I've updated the DailyLossLimit and DailyLosLimitMultiTrade examples that were posted on the forum for NinjaTrader 7 for NinjaTrader 8. These are often requested and I felt they are good examples to have for NT8. DailyLossLimitExample_NT7 - http://ninjatrader.com/support/forum...241#post451241 (http://ninjatrader


    To view the example, follow these steps:
    • Download the DailyLossLImitBuilderExample_NT8.zip file from the link
    • Go to Control Center > Tools > Import > NinjaScript AddOn
    • Select the file you downloaded
    Once the import is successful, you may open the Strategy Builder and select this strategy from the list of available strategies and click through the builder screens to review how it is set up.

    Please let me know if I may be of further assistance.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by NullPointStrategies, Today, 05:17 AM
    0 responses
    52 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    130 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    70 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    44 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    49 views
    0 likes
    Last Post TheRealMorford  
    Working...
    X