Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Access last entry price, limit number of trades

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

    Access last entry price, limit number of trades

    Hi,
    My system trades intraday. I would like to add 3 conditions:

    1. Trade only after 10 AM EST.
    2. Trade maximum 3 times in a session.
    3. On the second and third trade, enter only if the price is higher than the last trade that day.

    Can you please show me how to write those conditions?

    Thanks a lot.

    #2
    Hello GoGetIt,

    Thanks for the post.

    1. Trade only after 10 AM EST.
    This sample here can help with time filters in your strategy.

    2. Trade maximum 3 times in a session.
    You can use an int counter each time you make a trade and reset this counter at the start of each day using FirstBarOfSession. This sample can help reset values each day.

    3. On the second and third trade, enter only if the price is higher than the last trade that day.
    This involves more custom coding to keep track of the values you want. If you want to get the fill price of orders, will need to work with advanced handlers, and expose values with IExecution interface.
    Ryan M.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by AaronKoRn, Today, 09:49 PM
    0 responses
    6 views
    0 likes
    Last Post AaronKoRn  
    Started by carnitron, Today, 08:42 PM
    0 responses
    9 views
    0 likes
    Last Post carnitron  
    Started by strategist007, Today, 07:51 PM
    0 responses
    10 views
    0 likes
    Last Post strategist007  
    Started by StockTrader88, 03-06-2021, 08:58 AM
    44 responses
    3,977 views
    3 likes
    Last Post jhudas88  
    Started by rbeckmann05, Today, 06:48 PM
    0 responses
    9 views
    0 likes
    Last Post rbeckmann05  
    Working...
    X