Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Strategy Builder - configure a profit target condition?

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

    Strategy Builder - configure a profit target condition?

    Does anyone know how I could run an automated strategy until profit hits $50.00 (total PnL?)? But stop running if we go negative $50.00?
    Last edited by MatthewLesko; 03-09-2021, 12:52 AM.

    #2
    Hello MatthewLesko,

    Thank you for your post.

    Yes, in the Strategy Builder you could create a set of conditions to check whether your realized PnL is greater or less than your values, and set a bool to control whether the strategy can enter again. I've created a simple strategy builder strategy that runs in real time only (please test with the Sim101 account on a live chart) and submits a long order with a stop and target if the current position is flat and a bool called OKtoTrade is true. When the strategy sees that the realized PnL is greater or less than the ProfitPnL or LossPnL, the bool is changed to false and the strategy will not enter further trades.

    Please let us know if we may be of further assistance to you.
    Attached Files
    Kate W.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by DanielTynera, Today, 01:14 AM
    0 responses
    2 views
    0 likes
    Last Post DanielTynera  
    Started by yertle, 04-18-2024, 08:38 AM
    9 responses
    40 views
    0 likes
    Last Post yertle
    by yertle
     
    Started by techgetgame, Yesterday, 11:42 PM
    0 responses
    12 views
    0 likes
    Last Post techgetgame  
    Started by sephichapdson, Yesterday, 11:36 PM
    0 responses
    2 views
    0 likes
    Last Post sephichapdson  
    Started by bortz, 11-06-2023, 08:04 AM
    47 responses
    1,615 views
    0 likes
    Last Post aligator  
    Working...
    X