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

High/Low currently shown on Screen

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

    High/Low currently shown on Screen

    While daytrading futures I like to have my charts at a minimum-scale - during quiet periods the chart could look allover the place while in reality price's only moving in a tiny range. Therefore I added some very simple chart markers at my preferred minimum-distance with auto-scale = enabled.

    Now I would make this more general, e.g. automatically adjusting for different instruments and/or intervals.

    Here's my question: is there any possibility to get the highest/lowest value CURRENTLY SHOWN ON A CHART (I mean, the Min/Max of the data shown on the screen, and not over a fixed amount of bars)? Getting this would help a lot to enable my markers only if the range currently existing on my screen becomes smaller than my desired minimum distance - and disable them if price-range on the screen exceeds this minimum-distance.

    I'm pretty sure, NT must use internally something similar to Min/Max-of-visible-area to determine the necessary scaling according to price-range on screen

    #2
    Unfortunately this is not supported. NT7 will provide fixed scaling which may help in your situation.
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      I'm really looking forward to NT7, the list of planned enhancements sounds amazing.

      But what I would need here is a "minimum scale" and not a "fixed scale".
      Assuming I like a minimum vertical scale-width of 200 ticks, the chart should remain at a vertical spacing of 200 ticks, even while all price on the chart may trade in a 50-ticks-range only. But - and here's the difference to "Fixed Scaling" - if price on my chart trades in a 300-tick-range, I certainly want to show/see the full 300-ticks-range. Fixed scaling ( as e.g. Tradestation knows, too ) would CUT off some of the lower or upper price-action at the limits of the fixed scaling. Therefore I'm looking for "minimum scale"-functionality.

      What I already have, works acceptable as I'm simply "guessing" how many bars are shown on my chart; so I just read the MIN/MAX e.g. of the last 200 bars, and enable the auto-scale markers if the diffences goes below my minimum-distance - the only problem is that this "guessed" 200 bars to check is completely wrong if I shrink the window to e.g. only 50 bars - or if I switch from bar-charts to candlesticks etc.

      Comment


        #4
        ... and of course this scale-limits should be relative to price-action - there's no sense in setting a YM-chart to a fixed-absolute range , e.g. 10'000 to 10'200 - and adjust it everyday because price is trading at 8'300 to 8'500 like today

        Comment


          #5
          I suggest you just take the last price and calculate your range yourself to add your min/max plots.
          Josh P.NinjaTrader Customer Service

          Comment


            #6
            Thanks for your quick answers. I think we can close this track here as you already told me that it's currently not supported to get the MIN/MAX of the chart (or the number of bars on the chart which would help exactly as much).

            Comparing my wish-distance with the distance between MAX(200) and MIN(200) works better than comparing to the last price, because with your solution last price would always be centered in the middle of my chart (an option TS provides, too) - but this I don't like.

            Maybe a future version of NT will support a "minimal relative scale" (which is very easy to implement once you know the number of bars currently shown on a chart), but for now I can live with my automated "Spacer"-function - it's only a "little unnice" but no real problem.

            So, thanks again - and I do look forward to NT7 (for many other reasons)!

            Comment


              #7
              Thank you for the suggestion.

              To clarify, getting the number of displayed bars on a chart at any given time is not supported. To get the number of bars on the chart in total you can use CurrentBar.
              Josh P.NinjaTrader Customer Service

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by mishhh, 05-25-2010, 08:54 AM
              19 responses
              6,189 views
              0 likes
              Last Post rene69851  
              Started by gwenael, Today, 09:29 AM
              0 responses
              3 views
              0 likes
              Last Post gwenael
              by gwenael
               
              Started by Karado58, 11-26-2012, 02:57 PM
              8 responses
              14,829 views
              0 likes
              Last Post Option Whisperer  
              Started by Option Whisperer, Today, 09:05 AM
              0 responses
              1 view
              0 likes
              Last Post Option Whisperer  
              Started by cre8able, Yesterday, 01:16 PM
              3 responses
              11 views
              0 likes
              Last Post cre8able  
              Working...
              X