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 Mindset, 04-21-2026, 06:46 AM
          0 responses
          64 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Started by M4ndoo, 04-20-2026, 05:21 PM
          0 responses
          93 views
          0 likes
          Last Post M4ndoo
          by M4ndoo
           
          Started by M4ndoo, 04-19-2026, 05:54 PM
          0 responses
          48 views
          0 likes
          Last Post M4ndoo
          by M4ndoo
           
          Started by cmoran13, 04-16-2026, 01:02 PM
          0 responses
          106 views
          0 likes
          Last Post cmoran13  
          Started by PaulMohn, 04-10-2026, 11:11 AM
          0 responses
          63 views
          0 likes
          Last Post PaulMohn  
          Working...
          X