Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Priceline Indicator Anomalies

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

    Priceline Indicator Anomalies

    The NinjaTrader 8.1.3.0 Priceline indicator seems to be behaving strangely.

    On a EURUSD chart when the Forex market is closed, the data presents correctly as expected, even though it is after market hours.
    Now:
    1. Add the Priceline indicator. Select the three available lines (Ask, Bid, Last).
    2. Behaviour can vary, but typically it produces no lines on the chart. It can, however, also go immediately to the issue described in the point below (point 3).
    3. Reload NinjaScript. Now all bars disappear, the Y-axis price information disappears, and the lines are bunched as a single yellow line at the top of the chart.
    4. Remove the indicator. The chart reverts to a correct display of the data.
    The behaviour is not consistently reproducible except in being aberrant one way or another. If one presses F5 several times, sometimes the behaviour above occurs, but also sometimes when the aberrant view described above is showing, pressing F5 can restore the expected view, albeit without any price lines. This would seem to point to (at least) some form of timing issue in the indicator, amongst other possible bugs.

    Also, more generally, I note that one can select the indicator lines and that highlights the indicator name, at which point one can right-click on the lines or the name for a small menu that allows access to the indicator properties and removal of the indicator etc. This is good. However, wouldn't it also be sensible to be able to simply select via the displayed indicator name, and even directly right-click on that name for the same effect, rather than only on the lines?

    Thanks.
    Multi-Dimensional Managed Trading
    jeronymite
    NinjaTrader Ecosystem Vendor - Mizpah Software

    #2
    Hello jeronymite,

    Thanks for your post.

    I am not able to reproduce the behavior at this time likely because the markets are not closed.

    We will test this further when the FOREX markets are closed to see if we are able to reproduce the behavior you are reporting.

    If possible, please provide us with a short demonstration video showing the behavior you are reporting so we may see what you are seeing.

    As for your other note, that is the expected behavior. When selecting the indicator plots on the chart, you could right-click on the plots and select Properties to bring up the Indicators window, or you could double-click on the plots on the chart to bring up the Indicators window. Selecting the indicator label in the top-left corner of the chart will not bring up the Indicators window. Please let us know if you would like us to submit a feature request to the Development team so they may consider implementing this in a future NinjaTrader release.
    Brandon H.NinjaTrader Customer Service

    Comment


      #3
      Hello jeronymite,

      Thanks for your notes.

      I have still not been able to reproduce the behavior on my end when testing the Price Line indicator that comes with NinjaTrader.

      If possible, please provide us with a short demonstration video showing the behavior you are reporting so we may see what you are seeing.

      We look forward to assisting further.
      Brandon H.NinjaTrader Customer Service

      Comment


        #4
        Thanks, NinjaTrader_BrandonH. I think the "trick" is to add the indicator to a chart that has not yet received any real-time data since the indicator was added. That is certainly going to be the case when the market is closed, but I also saw the issue just now during normal Forex market hours by adding the indicator during what is obviously a "slow" period. The problem happened immediately because there was no additional real-time data after the indicator was added. As soon as a real-time data tick arrived, the problem did not happen.

        This would seem to point to an initialisation issue in the code. It would make sense to initialise the relevant values to the last data received so as to avoid any issue with "default" values such as double.MaxValue.

        I hope that helps.

        Edit: It's also seems that the indicator does not attempt to paint lines after initialisation until data arrives (or some other unusual set of conditions), because if some data has already arrived, preventing the "main" issue noted here, pressing F5 repeatedly every second or so causes the lines to appear and disappear alternately on each press until a new data tick arrives.

        Edit: Also, more generally, as I note in my original post, "one can select the indicator lines and that highlights the indicator name, at which point one can right-click on the lines or the name for a small menu that allows access to the indicator properties and removal of the indicator etc". I also said it would "be sensible to be able to simply select via the displayed indicator name, and even directly right-click on that name for the same effect, rather than only on the lines", to which you responded with an offer to submit this latter recommended behaviour as an enhancement request. Yes, please.

        Thanks.
        Last edited by jeronymite; 04-17-2024, 10:25 PM. Reason: Additional observations, and additional comment on original post.
        Multi-Dimensional Managed Trading
        jeronymite
        NinjaTrader Ecosystem Vendor - Mizpah Software

        Comment


          #5
          Hello jeronymite,

          Thanks for your notes.

          This would be the expected behavior of the PriceLine indicator since it uses OnMarketData() to get the bid/ask/last price values.

          From the OnMarketData() help guide: "By default, this method is not called on historical data, however, it can be called historically by using TickReplay"

          OnMarketData(): https://ninjatrader.com/support/helpGuides/nt8/onmarketdata.htm​

          You could enable Tick Replay so OnMarketData() is called historically.

          Tick Replay: https://ninjatrader.com/support/help...ick_replay.htm
          Brandon H.NinjaTrader Customer Service

          Comment


            #6
            Thanks, NinjaTrader_BrandonH

            I would recommend that to work "sensibly", the initialisation should set the required line values to the last known appropriate data values. That is not the same as OnMarketData "being called". It is initialising in a sensible way to avoid aberrant displays when data has been received prior to adding the indicator to the chart.

            This applies to situations when there will be no data for some time due to the market being closed, but also applies to real-time data when the market is slow. In both these situations, the behaviour is aberrant until the next data tick arrives. The fix is simple and effective.

            Also, perhaps you would comment on the two edits I added in my post above?

            Thanks.
            Multi-Dimensional Managed Trading
            jeronymite
            NinjaTrader Ecosystem Vendor - Mizpah Software

            Comment


              #7
              Hello jeronymite,

              Thanks for your notes.

              You could enable Tick Replay to have OnMarketData() calculate historically which would place the Price Line indicator lines at the last historically calculated value when the market is closed or when the market is slow and no real-time ticks are being received.

              See the help guide documentation below for more information.

              OnMarketData(): https://ninjatrader.com/support/helpGuides/nt8/onmarketdata.htm​
              Tick Replay: https://ninjatrader.com/support/help...ick_replay.htm
              Brandon H.NinjaTrader Customer Service

              Comment


                #8
                NinjaTrader_BrandonH The point is that the indicator can and should be improved to remove the aberrant behaviour in such circumstances. The fix is easy and would be effective. People should not be required to have the overhead of enabling another feature to overcome a problem in a simple indicator.

                Also, you have yet to address the two edit points I made.

                Thanks.
                Multi-Dimensional Managed Trading
                jeronymite
                NinjaTrader Ecosystem Vendor - Mizpah Software

                Comment


                  #9
                  Hello jeronymite,

                  Thanks for your notes.

                  I have submitted your feature request to the Development team so they may take it into consideration. This request is being tracked under the number SFT-6271.

                  In the meantime, Tick Replay would need to be used with the PriceLine indicator so that OnMarketData() calculates historically.

                  " It's also seems that the indicator does not attempt to paint lines after initialisation until data arrives"

                  Since the PriceLine indicator uses OnMarketData() it will only process incoming realtime data when applied to a chart. If there is no realtime data, the indicator does not display on the chart until realtime data comes in. This is because the indicator uses OnMarketData() to get values and OnMarketData() is not called on historical data by default.

                  As previously mentioned, you will need to enable Tick Replay to have the PriceLine indicator calculate historically since it uses OnMarketData().

                  See this help guide page about OnMarketData(): https://ninjatrader.com/support/help...marketdata.htm

                  "be sensible to be able to simply select via the displayed indicator name, and even directly right-click on that name for the same effect, rather than only on the lines"

                  I have submitted this feature request to the Development team. This request is being tracked under the number SFT-6272.

                  As with all feature requests, interest is tracked before implementation is considered, so we cannot offer an ETA or promise of fulfillment. If implemented, it will be noted on the Release Notes page of the Help Guide.

                  Release Notes — https://ninjatrader.com/support/help...ease_notes.htm
                  Brandon H.NinjaTrader Customer Service

                  Comment

                  Latest Posts

                  Collapse

                  Topics Statistics Last Post
                  Started by bc24fl, 08-30-2019, 01:58 PM
                  3 responses
                  253 views
                  0 likes
                  Last Post PaulMohn  
                  Started by tradingnasdaqprueba, 04-09-2024, 09:52 AM
                  6 responses
                  26 views
                  0 likes
                  Last Post tradingnasdaqprueba  
                  Started by PaulMohn, Today, 02:06 AM
                  1 response
                  3 views
                  0 likes
                  Last Post PaulMohn  
                  Started by Mindset, Today, 01:27 AM
                  0 responses
                  5 views
                  0 likes
                  Last Post Mindset
                  by Mindset
                   
                  Started by EB Worx, 03-07-2023, 05:05 AM
                  4 responses
                  99 views
                  1 like
                  Last Post cls71
                  by cls71
                   
                  Working...
                  X