Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

lowest Low

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

    lowest Low

    hello

    i have an interesting strategy in tradestation format, and would like to know how to buy 1 tick above the Bar with the Lowest(LOW, 3) in ninjatrader script?




    B1(2), // Long momentum length
    S1(16), // Short momentum length
    B2(4), // Long RSI length
    S2(9) // Short RSI Length



    If (Momentum( CLOSE , B1) > 0 and RSI( CLOSE , B2) CROSS UNDER 60) then begin
    BUY ("B1")cntracts CONTRACT NEXT BAR Lowest( LOW , 3) + 0.01 LIMIT ;
    end;
    If (Momentum( CLOSE , S1) < 0 and RSI( CLOSE , S2) CROSS OVER 40) then begin
    SELLSHORT ("S1")cntracts CONTRACT NEXT BAR Highest( HIGH , 3) - 0.01 LIMIT ;
    end;

    #2
    Hi tradereight,

    To buy at a certain price you would either want to use EnterLongLimit() or EnterLongStop().

    To submit an order of the price you want you can use MIN().
    Code:
    MIN(Low, 3)[0]
    Code:
    if (some condition)
         EnterLongLimit(100, MIN(Low, 3)[0] + 1 * TickSize);
    Last edited by NinjaTrader_JoshP; 10-27-2008, 03:01 PM.
    Josh P.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    62 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    35 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    54 views
    1 like
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    61 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    48 views
    0 likes
    Last Post CarlTrading  
    Working...
    X