Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Volume up and down

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

    Volume up and down

    I understand I can access the value of volume for the current bar by assigning VolumeUpDown()[0] to a variable, but it's not specific to up or down, how do I identify if the number returned refers to up or down in the code?

    #2
    Hello, thanks for writing in.

    You would need to check the price of the bar to know if the bar is up or down e.g.

    if(Close[0] > Open[0])
    {
    //green bar
    }
    else if(Close[0] < Open[0])
    {
    //red bar
    }

    Comment


      #3
      Oh, I see... so it does not identify whether it's a sell or a buy, it only shows if it's really up or down from previous...
      Is there a way to identify if the volume is long or short?

      Comment


        #4
        Hi, thanks for your reply

        You would need to use the BuySellVolume indicator to separate the buys and sells. VolumeUpDown is just a regular total volume indicator that colors the plot based on the direction of the bar.

        Best regards.

        Comment


          #5
          Thank you

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by SalmaTrader, 07-07-2026, 10:26 PM
          0 responses
          35 views
          0 likes
          Last Post SalmaTrader  
          Started by CarlTrading, 07-05-2026, 01:16 PM
          0 responses
          20 views
          0 likes
          Last Post CarlTrading  
          Started by CaptainJack, 06-17-2026, 10:32 AM
          0 responses
          12 views
          0 likes
          Last Post CaptainJack  
          Started by kinfxhk, 06-17-2026, 04:15 AM
          0 responses
          18 views
          0 likes
          Last Post kinfxhk
          by kinfxhk
           
          Started by kinfxhk, 06-17-2026, 04:06 AM
          0 responses
          20 views
          0 likes
          Last Post kinfxhk
          by kinfxhk
           
          Working...
          X