Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

One Trade Per Day

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

    One Trade Per Day

    Is there an easy way to add an input to an existing strategy to select the number of trades per day? I would like to test a specific number of trades per day starting with 1 trade per day.

    Thank you.

    #2
    Hello JerryA,

    Thank you for your post.

    The ease of implementing will depend on your knowledge of NinjaScript. You would use Bars.FirstBarOfSession and a user defined input.

    Bars.FirstBarOfSession: http://www.ninjatrader.com/support/h...ncesession.htm

    Information on user defined input: http://www.ninjatrader.com/support/f...ead.php?t=5782

    Please let me know if you have any questions.

    Comment


      #3
      Hi Jerry,

      I would simply add a parameter of how many trades per day you want to do.

      Then I would use OnPositionUpdate to increment a variable everytime my position goes from flat to something. In addition to this, OnBarUpdate I would reset that variable each time Bars.GetTimeEnd(CurrentBar).Day != Bars.GetTimeEnd(CurrentBar - 1).Day.

      Needless to say that you must have CurrentBar > 0 and that you will enter a trade only if your variable is < how many trades you want to take in a day.

      Cheers!

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Geovanny Suaza, 02-11-2026, 06:32 PM
      0 responses
      647 views
      0 likes
      Last Post Geovanny Suaza  
      Started by Geovanny Suaza, 02-11-2026, 05:51 PM
      0 responses
      368 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
      571 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