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

MAX/MIN in CalculateOnBarClose = false [DUDE]

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

    MAX/MIN in CalculateOnBarClose = false [DUDE]

    Hello,

    I have a question, I want that when I recive entry signal in market, in the same moment, this bar draw square, and draw squares in all next bars with maximum or minimum than the previous bar.
    Finally, I need to draw line to connect the first bar entry with the last bar square

    Thank you!!

    Ricard

    #2
    This sounds like Chinese. Even with the best intentions I cannot understand your question.

    Could you reformulate or translate it to plain English please?

    Comment


      #3
      Hello AgueroSala and Harry, I think that aguerosala what to say is:

      As an indicator either I get an entry marked with an arrow marking up or down.
      I get exactly the point of entry into this candle we remember that we are with the Calculateonbarclose = false option.
      Once the entry has been in the same real-time candle I want to draw a square.
      This square will own to pursue the price so that this drawing is always a maximum or minimum , starting from the entrance obviously we will obey obtained in a variable.
      To give you an example : The indicator gives a bullish candle entry 1, the entry is marked by an upward arrow.
      At the same moment will draw a square at maximum the same candle, the same instant . As the candle grows obtain new highs and therefore the square will be moving up , never down . In the sail 2 if the square sail one is surpassed and is created in the sail 2 a new high , square sail 1 is removed is drawn on the sail 2 in the new high.

      Comment


        #4
        Now it sounds like Japanese, I still do not understand much of it. It is not yet comprehensible.

        The only thing that I get is that you wish to draw an entry and then some squares. Could you please post a chart showing what you really wish to do?

        Comment


          #5
          Sorry for the language , obviously I am not English-speaking , but I think you get enough. The only thing is that the concept is complex to explain.

          Note that I be Chinese if you want to be more comfortable to talk to me in Chinese

          JAPAN: こちらをご覧ください
          CHINESE: 得知

          As you can see is quite different from your language.

          The important thing is that I have now made a picture for you to understand the operation of the above.
          Attached Files

          Comment


            #6
            Should be easy to draw the square. If you use the same tag for all squares, it will be displaced from one high to the next high of a bar. The tag could read tag = "square" + entryBar, where entryBar is the CurrentBar when the position was entered.

            For the arrow there could be a problem, as the exact location of the arrow must be calculated somehow. Even with the indicator set to CalculateOnBarClose = False, the calculation will only take place after the bar close if you perform it on historica data. If you are looking at real-time data, pressing F5 may therefore shift the arrow.

            The line connecting arrow and square is redrawn, when a new square is printed. Here you would also need the same tag such as tag = "line" + entryBar to make sure that the line is displaced as needed.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Rapine Heihei, 04-23-2024, 07:51 PM
            2 responses
            30 views
            0 likes
            Last Post Max238
            by Max238
             
            Started by Shansen, 08-30-2019, 10:18 PM
            24 responses
            943 views
            0 likes
            Last Post spwizard  
            Started by Max238, Today, 01:28 AM
            0 responses
            9 views
            0 likes
            Last Post Max238
            by Max238
             
            Started by rocketman7, Today, 01:00 AM
            0 responses
            4 views
            0 likes
            Last Post rocketman7  
            Started by wzgy0920, 04-20-2024, 06:09 PM
            2 responses
            28 views
            0 likes
            Last Post wzgy0920  
            Working...
            X