Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Limit # of trades taken per session

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

    Limit # of trades taken per session

    Hello... I have my session set for a couple hours at the open and my strategy takes from 0 - 6 trades during that time. I'm wondering if I can set a max # of trades to take, like 1 or 2 per day (example). I'm trading TF 12-12 with Renko based data.

    Thank you.

    #2
    Originally posted by Dia1496 View Post
    Hello... I have my session set for a couple hours at the open and my strategy takes from 0 - 6 trades during that time. I'm wondering if I can set a max # of trades to take, like 1 or 2 per day (example). I'm trading TF 12-12 with Renko based data.

    Thank you.
    You are using a strategy?

    Did you build it or someone else?

    Are you using the strategy builder, or is this custom code?

    You'll need to add a variable for the total trades taken, and add that as a condition.

    Comment


      #3
      Originally posted by Dia1496 View Post
      Hello... I have my session set for a couple hours at the open and my strategy takes from 0 - 6 trades during that time. I'm wondering if I can set a max # of trades to take, like 1 or 2 per day (example). I'm trading TF 12-12 with Renko based data.

      Thank you.
      Something like this post, but with integers counting your trades and stopping after x #

      Comment


        #4
        I set up a basic strategy utilizing the Strategy Wizard as a start for learning how to back test. And yes that is what I am asking for is a variable for the total number of trades taken (in that session). Not for the whole time period I am running the backtest, so it CANrestart the next session.

        Comment


          #5
          Dia,

          Unfortunately I am not aware of a way to do this in the Strategy Wizard by itself. Likely you will need to program this.
          Adam P.NinjaTrader Customer Service

          Comment


            #6
            Originally posted by Dia1496 View Post
            I set up a basic strategy utilizing the Strategy Wizard as a start for learning how to back test. And yes that is what I am asking for is a variable for the total number of trades taken (in that session). Not for the whole time period I am running the backtest, so it CANrestart the next session.
            This would get ugly.

            I believe this would work to limit to 1 long trade.

            You'll need another "set" of checks to check for 2 trades, add variable0 checks in set2 for variable0 = 0, then in set 3, check for marketposition.long, variable =1 , and then set variable0 to 2....etc.
            Attached Files

            Comment

            Latest Posts

            Collapse

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