Volume Accumulation Percentage Indicator (VAPI) is a variation of the classic volume-accumulation indicators. It uses volume the same way as OBV except that it assigns volume weights based on intraday volatility.

In a positive trend, if the stock price is close to a (local) new high, the VAPI should be at its maximum as well (and vice versa for a negative trend). If the market is looking for a direction, if the price is in the bottom side of his current trading range and if, at the same moment the VAPI osc slopes up, there is accumulation on the stock and that the prices should start to climb. The SELL signal is given when the VAPI decreases (distribution). Divergences are usually very effective too.

Tuning the "length" parameter may be needed for your instrument (default is 10), do let me know if you find a different value to be optimal for majority of instruments.

### thinkScript Code

Code:

```
# Volume Accumulation Percentage Indicator [LazyBear]
# Assembled by BenTen at useThinkScript.com
# Converted from https://www.tradingview.com/script/kVk6pN9z-Volume-Accumulation-Percentage-Indicator-LazyBear/
declare lower;
input length = 10;
def x = (2 * close - high - low) / (high - low);
def tva = sum(volume * x, length);
def tv = sum(volume, length);
def va = 100 * tva / tv;
plot ZeroLine = 0;
plot histogram = va;
plot line = va;
histogram.SetPaintingStrategy(PaintingStrategy.HISTOGRAM);
histogram.assignValueColor(if va > 0 then Color.green else Color.red);
```