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

1 trade at a time across all stocks

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

    1 trade at a time across all stocks

    Hi NinjaTrader

    I'm trying to make a backtesting more realistic and wonder if it is possible to apply the:
    Code:
    EntriesPerDirection = 1;
    logic to the entire list of stocks.

    In other words, when I backtest a strategy on a list of 300+ stocks, I will achieve this but only for one particular stock - many more trades will take place on the remaining stocks.

    Is there a way to program a condition that accross the whole list of stocks which is backtested only 1 trade can take place at a time (the next one can be opened only once the 1st one is closed)

    I believe this will give a better picture as to how much and how fast my account will change, because I will be trading in this manner.

    #2
    Hi ionaz, thanks for the post - unfortunately the strategies would not cross communicate, meaning the EntriesPerDirection would only be valid in the single strategy instance currently run / processed. What you could do however is create a MultiSeries strategy with your instruments that would trade your list, this would let you simulate only having one position open - however would mean more advanced custom coding is needed to realize.
    BertrandNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by llanqui, Today, 03:53 AM
    0 responses
    6 views
    0 likes
    Last Post llanqui
    by llanqui
     
    Started by burtoninlondon, Today, 12:38 AM
    0 responses
    10 views
    0 likes
    Last Post burtoninlondon  
    Started by AaronKoRn, Yesterday, 09:49 PM
    0 responses
    15 views
    0 likes
    Last Post AaronKoRn  
    Started by carnitron, Yesterday, 08:42 PM
    0 responses
    11 views
    0 likes
    Last Post carnitron  
    Started by strategist007, Yesterday, 07:51 PM
    0 responses
    14 views
    0 likes
    Last Post strategist007  
    Working...
    X