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

How to: Create a strategy using variable dollar values, rather than integer shares.

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

    How to: Create a strategy using variable dollar values, rather than integer shares.

    Hi,

    How can i create a strategy where i can go long for a value of shares in $x rather than a fixed number?
    And then how can i use this $x again for TP1 and TP2 for example?

    Ie,
    Take INTC stock.

    My long is triggered when the stock price is $50. My size is $1000. So i want NT8 to know that my preferred entry is $1000/50 = 20.
    But afterwards, i need this 20 shares stored somewhere as a variable. Because i want to program, Take Profit 1 as 75% of my size (15), and then leave 5 shares until TP2.
    It would also have to adjust my Stop loss too, because it was 20 shares, and after TP1 is hit, my SL would be for 5 shares.

    Any way to do this?

    Thanks


    #2
    Hello gaz0001,

    You would need to custom calculate a quantity of shares based on custom math.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_ChelseaB View Post
      Hello gaz0001,

      You would need to custom calculate a quantity of shares based on custom math.
      http://ninjatrader.com/support/forum...841#post493841

      ​​​​​​Thanks, looks a bit complicated for my 3day NT8 3xperience,but I will surely give it a good read and have a crack at it.

      Thanks again

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Taddypole, 04-26-2024, 02:47 PM
      1 response
      12 views
      0 likes
      Last Post NinjaTrader_Eduardo  
      Started by futtrader, 04-21-2024, 01:50 AM
      6 responses
      58 views
      0 likes
      Last Post futtrader  
      Started by sgordet, Today, 11:48 AM
      0 responses
      4 views
      0 likes
      Last Post sgordet
      by sgordet
       
      Started by Trader146, Today, 11:41 AM
      0 responses
      5 views
      0 likes
      Last Post Trader146  
      Started by jpapa, 04-23-2024, 07:22 AM
      2 responses
      22 views
      0 likes
      Last Post rene69851  
      Working...
      X