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 llanqui, Yesterday, 09:59 AM
      4 responses
      22 views
      0 likes
      Last Post llanqui
      by llanqui
       
      Started by smartromain, 03-13-2024, 01:42 AM
      5 responses
      93 views
      0 likes
      Last Post AndreiBig  
      Started by Noerclou, Today, 04:55 AM
      0 responses
      5 views
      0 likes
      Last Post Noerclou  
      Started by ThoriSten, Today, 03:56 AM
      0 responses
      6 views
      0 likes
      Last Post ThoriSten  
      Started by PhillT, 04-19-2024, 02:16 PM
      3 responses
      26 views
      0 likes
      Last Post mangel2000  
      Working...
      X