Buy/Sell Volume Totals for Period
Jan 5, 2022

The Buy/Sell Volume Totals for Period indicator calculates and aggregates intraday buying and selling pressure within a user-defined timeframe to help identify phases of Wyckoff accumulation or distribution.
Usage
The Usage section describes how the script can be used to analyze volume dynamics over a specific trading range. By defining a start and end date, traders can isolate a specific price structure—such as a consolidation or a trading range—to see if the net volume flow supports a bullish or bearish breakout.
- Identifying Accumulation: When the cumulative buy volume exceeds the cumulative sell volume within the selected period, the background colors green. This suggests that demand is absorbing supply, a key characteristic of Wyckoff accumulation.
- Identifying Distribution: When the cumulative sell volume is greater than the cumulative buy volume, the background colors red. This indicates that supply is overwhelming demand, pointing toward potential distribution.
- Monitoring Volume Ratios: Users can track the ratio of total buy volume to total sell volume. A ratio significantly above 1.0 indicates strong buying dominance, while a ratio below 1.0 suggests selling dominance.
Details
The script calculates buy and sell volume for each candle based on price action relative to the candle's range. If the close is near the high, a larger portion of the volume is attributed to buying; if the close is near the low, more is attributed to selling.
The core logic aggregates these values starting from the "Start Time" input. If "Use End Time" is enabled, the calculation stops at the specified date; otherwise, it continues to the current candle. The indicator uses a proportional volume algorithm:
- Buy Volume: $Volume \times \frac{Close - Low}{High - Low}$
- Sell Volume: $Volume \times \frac{High - Close}{High - Low}$
This methodology provides a more granular view of volume flow than standard volume bars by segmenting the internal pressure of every candle before totaling them over the period.
Settings
- Start Time: Determines the beginning of the period for volume aggregation.
- Use End Time?: A toggle to decide whether the calculation should stop at a specific date or continue to the most recent data.
- End Time: Determines the concluding timestamp for the volume aggregation if "Use End Time?" is active.
FAQ
How do I interpret the background colors? A green background indicates that total buy volume is currently higher than total sell volume for the selected period, suggesting accumulation. A red background indicates that total sell volume is higher, suggesting distribution.
Can I use this for any timeframe? Yes, the indicator can be applied to any timeframe. However, it is most effective when the start and end times are aligned with significant market pivots or the start of a recognized Wyckoff trading range.
How do I access Buy/Sell Volume Totals for Period? You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.
Trading & investing are risky and many will lose money in connection with trading and investing activities. All content on this site is not intended to, and should not be, construed as financial advice. Decisions to buy, sell, hold or trade in securities, commodities and other investments involve risk and are best made based on the advice of qualified financial professionals. Past performance does not guarantee future results.
Hypothetical or Simulated performance results have certain limitations. Unlike an actual performance record, simulated results do not represent actual trading. Also, since the trades have not been executed, the results may have under-or-over compensated for the impact, if any, of certain market factors, including, but not limited to, lack of liquidity. Simulated trading programs in general are designed with the benefit of hindsight, and are based on historical information. No representation is being made that any account will or is likely to achieve profit or losses similar to those shown.
Testimonials appearing on this website may not be representative of other clients or customers and is not a guarantee of future performance or success.
As a provider of technical analysis tools and strategies, we do not have access to the personal trading accounts or brokerage statements of our customers. As a result, we have no reason to believe our customers perform better or worse than traders as a whole based on any content, tool, or platform feature we provide.
Charts used on this site are by TradingView in which the majority of our technical indicators are built on. TradingView® is a registered trademark of TradingView, Inc. www.TradingView.com TradingView® has no affiliation with the owner, developer, or provider of the Services described herein.
Market data is provided by CBOE, CME Group, BarChart, Massive, CoinAPI. Select U.S. equities data is provided through Massive. CBOE BZX real-time U.S. equities data is licensed from CBOE and provided through BarChart. Real-time futures data is licensed from CME Group and provided through BarChart. Select cryptocurrency data, including major coins, is provided through CoinAPI. All data is provided “as is” and should be verified independently for trading purposes.
This does not represent our full Disclaimer. Please read our full disclaimer.
© 2026 LuxAlgo Global, LLC.

