Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Entry Prices For Bonds [ZB]

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

    Entry Prices For Bonds [ZB]

    I am writing a strategy for use on the ZB (30Yr Bond Future)--and I am getting some strange fills -or at least strange trade displays on the chart.

    I understand that the ZB is plotted in 32's - but are the internal prices on the bar data (open , high, low, close)--stored as decimal values?

    Here is my code for calc'ing the entry price: (Bracket is an integer of an offset--such as 2 which would be 2 ticks)--so in the following code--I want the entry price to be 2 ticks above the highest high from 5:20 Am to 6:20 AM

    entrypriceL = SampleGetHighLowByTimeRange(6, 20, 5, 20).HighestHigh[0]+(Bracket * TickSize);

    Is this the correct code for ZB?
    Jim-Boulder
    NinjaTrader Ecosystem Vendor - Elephant Tracks

    #2
    Hello Jim-Boulder,

    Thank you for your post.

    The internal bar data is going to be a decimal value. Represented by the 32nd's value times the TickSize

    Example 137'13 = 13 * 0.03125 = .40625 + 137 = 137.40625

    .03125 is the TickSize for the ZB.

    You want two ticks higher than you could take the Highest value + (2 * TickSize)

    Let me know if I can be of further assistance.
    Cal H.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

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