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

How to display chart marker, in a fixed place.

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

    How to display chart marker, in a fixed place.

    Guys, can someone tell me how to display the marker arrow, let's say arrow up, on the top, in the specified place in the charts when a certain condition is true, without reference to the bar and the Y-axis? For example, not as in DrawArrowUp ("tag1", true, 0, Low [0] - TickSize, Color.Red), similarly with DrawTextFixed.

    #2
    Hello Stock,

    Thank you for your post and welcome to the NinjaTrader Support Forum!

    The best example of custom plotting can be found by going to your NinjaTrader Control Center > Tools > Edit NinjaScript > Indicator > CustomPlotSample > OK.

    The methods used within this sample can be used to create your own custom plots at fixed regions on the chart if you wish.

    Please let me know if you have any questions.

    Comment


      #3
      Hello Patrick H. Thanks for quick answer. I'm going thru as you advised, but seems to me i don't have such sample. Can you tell me where can I get this sample?

      Comment


        #4
        Sorry, I just found.

        Comment


          #5
          I looked through the example and as far as I understand it, this method allows to only draw a rectangle or a text, right? How can I to draw a specific object such as an arrow up or a dot? Can you advise any method to use in order to drow exactly chart marker?
          Last edited by Stock; 02-14-2013, 01:05 PM.

          Comment


            #6
            Hello Stock,

            Thank you for your response.

            You can use DrawTextFixed and use the Wingdings3 font and the character 'h' for an up arrow.

            For a dot you can use any font that you wish and either '.' or '*' for the dot. Unfortunately, there is no DrawArrowFixed or DrawDotFixed method in NinjaScript.

            Please let me know if I may be of further assistance.

            Comment


              #7
              Originally posted by Stock View Post
              I looked through the example and as far as I understand it, this method allows to only draw a rectangle or a text, right? How can I to draw a specific object such as an arrow up or a dot? Can you advise any method to use in order to drow exactly chart marker?
              Use DrawString(), and any symbol font that has the kind of object that you want to draw. Wingdings font has quite a few symbols, or you can always download a font that has the exact symbol that you want.

              If you do not know what character represents the symbol, you can always use the default Windows System Tool called Character Map to copy and paste it into your indicator method.
              Last edited by koganam; 02-14-2013, 02:08 PM. Reason: Corrected punctuation.

              Comment


                #8
                Thank you, Patrick H.

                Comment


                  #9
                  Thank you, koganam! I'll try.

                  Comment


                    #10
                    Thanks guys, this works great!!!

                    Comment

                    Latest Posts

                    Collapse

                    Topics Statistics Last Post
                    Started by adeelshahzad, Today, 03:54 AM
                    2 responses
                    15 views
                    0 likes
                    Last Post adeelshahzad  
                    Started by dappa, Today, 09:18 AM
                    1 response
                    5 views
                    0 likes
                    Last Post NinjaTrader_ChelseaB  
                    Started by bill2023, Yesterday, 08:51 AM
                    5 responses
                    24 views
                    0 likes
                    Last Post bltdavid  
                    Started by frankthearm, Today, 09:08 AM
                    1 response
                    3 views
                    0 likes
                    Last Post NinjaTrader_Clayton  
                    Started by yertle, Today, 08:38 AM
                    2 responses
                    7 views
                    0 likes
                    Last Post yertle
                    by yertle
                     
                    Working...
                    X