Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

how to set a quantity to buy?

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

    how to set a quantity to buy?

    Hi i am using the strategy builder and how can i set a quantity standard like this: i am having $1000 as my budget and i want to use up the 1000 dollars, round to the most shares i can buy?
    in other words the system will calculate the correct quantity to buy by itself by exhaust the $1000 to the most. how can i code this strategy? i tried to put 1000/GetCurrentBid() into the strategy builder but it cannot recognize it. Please help me out! Thanks!!!!!!

    #2
    Hi light7801, unfortunately this is not directly supported in the wizard, you could calculate the position size needed via custom coding in NinjaScript.

    For an approximation of working based on margin / account size settings, you can use the 'ByAccountSize' mode to determine order qty -

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    152 views
    1 like
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    87 views
    1 like
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    131 views
    2 likes
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    127 views
    1 like
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    106 views
    0 likes
    Last Post CarlTrading  
    Working...
    X