Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Add Position Size on "X" Acct Equity Drawdown

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

    Add Position Size on "X" Acct Equity Drawdown

    I am looking for help with implementing an idea to change my strategy's position size once there is "X" account drawdown.
    I have attempted to use the documentation here

    Code:
    if (SystemPerformance.AllTrades.TradesPerformance.Currency.Drawdown >= 1000)
    {PositionFactor = 2;}
    if (SystemPerformance.AllTrades.TradesPerformance.Currency.Drawdown <= 0)
    {PositionFactor = 1;}
    The attached picture is to help communicate my intent. Combined with my code snippet intent, if the acct reaches $1000 down from equity high, I want to increase my position size (which I use PositionFactor to help do). Then when the account equity reaches new highs, turn the position size back to default until the $1000 drawdown is reached again.
    Any help would be appreciated. Thanks!

    #2
    Hello Mabba,

    Thanks for your post.

    Drawdown will be present as a negative number so your condition would need to be <= -1000.

    You can always use Print statement to print out the current value of drawdown: Print (Time[0]+" DrawDown: "+
    SystemPerformance.AllTrades.TradesPerformance.Curr ency.Drawdown);

    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Thank you for your feedback Paul. I changed the polarity and used Print() but the number didn't make sense to me. I wasn't able to get drawdown to do what I wanted, but I ended up using CumProfit to generate the number that I was looking for. Thanks!

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by jeronymite, Today, 08:43 PM
      0 responses
      2 views
      0 likes
      Last Post jeronymite  
      Started by jeronymite, Today, 07:01 PM
      0 responses
      7 views
      0 likes
      Last Post jeronymite  
      Started by LeitoGTR, Today, 06:41 PM
      0 responses
      6 views
      0 likes
      Last Post LeitoGTR  
      Started by 2inthebush, Today, 03:29 PM
      2 responses
      12 views
      0 likes
      Last Post 2inthebush  
      Started by forrestang, Today, 02:17 PM
      5 responses
      23 views
      0 likes
      Last Post NinjaTrader_ChrisL  
      Working...
      X