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

[BUG?] "Andrew Pitchfork" drawing tool loses and regains position

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

    [BUG?] "Andrew Pitchfork" drawing tool loses and regains position

    Hey guys,

    It seems to me that there is a bug with the "Andrew Pitchfork" drawing tool.
    The tool lines lose and regain position (fixed lines are Rays):

    Discover the magic of the internet at Imgur, a community powered entertainment destination. Lift your spirits with funny jokes, trending memes, entertaining gifs, inspiring stories, viral videos, and so much more from users like rafaelcoisa.

    (3min gif)

    To reproduce the bug:
    ES JUN23 - 2000 Tick
    Market Replay data
    Start 05/05/2023 (from the open market)

    So, bug or not bug?​
    Last edited by rafaelcoisa; 05-08-2023, 04:12 AM.

    #2
    Hello rafaelcoisa,

    I watched the video however I am not seeing what you described as the tool loosing and regaining its position, can you point out the specific times in that video where the tool is normal, then not normal?
    JesseNinjaTrader Customer Service

    Comment


      #3
      hey NinjaTrader_Jesse,

      The "bug" happens all the time.
      Look at the edge of the chart.
      There will be two lines, one light blue and one dark blue.​
      Try the 1:11 moment in the video. The two lines are quite separated.​
      Last edited by rafaelcoisa; 05-09-2023, 06:24 PM.

      Comment


        #4
        Hello rafaelcoisa,

        I am not sure I see any problem here. Are you referring to when the top line goes to the top panel and is no longer hitting the right panel?
        JesseNinjaTrader Customer Service

        Comment


          #5
          All 6 lines have the same slope.
          Why, when the scale changes, do the 3 pitchfork lines move (lose position, regain position) ?
          The 3 ray lines do not move.​

          Comment


            #6
            Hello rafaelcoisa,

            I am not sure what you are trying to explain here. From the video I see the 3 parallel blue lines projecting to the right of the chart. From what I can see they stay parallel and project to the edge. When the price moves up the scale gets larger so the lines move around some to adjust for the new scale. They still have the original price and are projecting to the part of the scale which would equate to the projection price.

            It may help if you take a screenshot of when it looks normal and a screenshot of what looks out of place and then mark the screenshot where you see the problem. I tried going to the timestamp you mentioned but it still looks right to me at that time.
            JesseNinjaTrader Customer Service

            Comment


              #7
              Why the ray lines never move around? Only the pitchfork lines do.

              Comment


                #8
                Hello rafaelcoisa,

                I am not sure what rays you are referring to. In the video you uploaded I only see the 3 lines the pitchfork is making. Those lines are like rays where they extend to the panel edge. You will need to provide more specific detail here as I am unable to see what problem you are describing in the video.
                JesseNinjaTrader Customer Service

                Comment


                  #9
                  minute 1:11
                  Click image for larger version

Name:	2023-05-10 182956.png
Views:	79
Size:	233.2 KB
ID:	1250970

                  Comment


                    #10
                    Hello rafaelcoisa,

                    And what do the numbers mean in this image?

                    As mentioned that looks like a normal drawing object with its lines extended to the edge of the panel. You need to provide specidc detail on what you thnk is the problem here, your previous description did not relay enough information to let me know what problem you think there is.
                    JesseNinjaTrader Customer Service

                    Comment


                      #11
                      On other platforms two lines with the same slope persist with the same slope regardless of price scale changes.​
                      If anyone knows how to fix this bug let me know.​

                      Comment


                        #12
                        Hello rafaelcoisa,

                        The drawing objects visual may change over time and move due to the scale changing to include more or less prices. The chart scale displays a variable range of prices. The chart scale may include a larger or smaller set of prices which make the price scale squeeze in or out to accommodate the visible bars. Because the scale is accommodating the visible bars you may see that the drawing object will move some vertically depending on the prices displayed and projected lines will change angles when more or less prices are included in the scale. The drawing object has not changed at all and is still pointing to the same prices, its visual changed because the chart scale changed.

                        The only way to prevent that would be to not allow the price scale to change. You can use a fixed price scale and that would not allow new higher highs or lower lows to extend the range which squeezes the chart in to accommodate viewing that data. If the scale stays the same the drawing object angles won't move at all when price data comes in.

                        JesseNinjaTrader Customer Service

                        Comment


                          #13
                          I think the lines 502 to 509 cannot be in OnRender.
                          OnRender messes with the calculations when the scale changes.​

                          Comment


                            #14
                            Hello rafaelcoisa,

                            If you removed that code that would prevent the tool from working, the lines you mentioned are only valid in OnRender. That is partially how it calculates the X/Y to render.

                            As mentioned previously I am not able to see a problem from the video and image you provided. The video just shows that the tool is moving on the scale with the price movement which would be normal. The image you provided has numbers but no explanation of what the numbers mean. An image would be helpful if you can provide a image showing when it looks correct vs when it does not look correct along with a specific description of what part is not correct.

                            JesseNinjaTrader Customer Service

                            Comment


                              #15
                              I think these lines should be removed from there and placed in a method to calculate the values with chartPanel like gann fan.​

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by burtoninlondon, Today, 12:38 AM
                              0 responses
                              9 views
                              0 likes
                              Last Post burtoninlondon  
                              Started by AaronKoRn, Yesterday, 09:49 PM
                              0 responses
                              14 views
                              0 likes
                              Last Post AaronKoRn  
                              Started by carnitron, Yesterday, 08:42 PM
                              0 responses
                              11 views
                              0 likes
                              Last Post carnitron  
                              Started by strategist007, Yesterday, 07:51 PM
                              0 responses
                              13 views
                              0 likes
                              Last Post strategist007  
                              Started by StockTrader88, 03-06-2021, 08:58 AM
                              44 responses
                              3,983 views
                              3 likes
                              Last Post jhudas88  
                              Working...
                              X