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

Market position $ Limit

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

    Market position $ Limit

    hi Guys, I'd appreciate someone advising how to place a limit on the % or $ amount of the account balance as a risk management control.

    For example, using the scenario of running the same automated strategy on 6 instruments. Assume the account balance is $100,000 and want to risk up to 1% of the account balance on total positions at any one time. i.e $1,000 with all trades being 2 contracts.

    Taking this example further assume the system has actioned the following trades and remains long in the trades:

    2 x trades on TF with a 20 tick stop - risk $400
    2x trades on CL with a 20 tick stop - risk $400

    Assuming a long for the Euro has been triggered while in these trades I don't want this 2 contract position being taken because it would breach the 1% threshold of $1000. It should only be taken if one of the other positions has been closed out.

    Anyone have ideas or example on how to achieve this or any alternatives if this is too difficult?

    Thanks in advance
    DJ

    #2
    Hello DJ,

    Thank you for your post.

    You can set the Strategy Property 'AccountSize' to accomplish this:



    Then you can set your desired Margin Value for each instrument you are trading from Tools--> Instrument Manager--> highlight the Instrument and select "Edit" which will open the Instrument Editor.

    Then when you are starting the strategy, you have the option to set the order quantity 'by account size' which will work off of these properties.
    MatthewNinjaTrader Product Management

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by mjairg, 07-20-2023, 11:57 PM
    3 responses
    213 views
    1 like
    Last Post PaulMohn  
    Started by TheWhiteDragon, 01-21-2019, 12:44 PM
    4 responses
    544 views
    0 likes
    Last Post PaulMohn  
    Started by GLFX005, Today, 03:23 AM
    0 responses
    3 views
    0 likes
    Last Post GLFX005
    by GLFX005
     
    Started by XXtrader, Yesterday, 11:30 PM
    2 responses
    12 views
    0 likes
    Last Post XXtrader  
    Started by Waxavi, Today, 02:10 AM
    0 responses
    7 views
    0 likes
    Last Post Waxavi
    by Waxavi
     
    Working...
    X