**Syntax**

```
public VWMA(Bars bars, int period, string description)
public static VMWA(Bars bars, int period, double deviations)
```

**Parameter Description**

*bars* | Bars object |

*period* | Indicator calculation period |

**Description**

The Volume Weighted Moving Average (VWMA) is the same a

simple moving average except that it gives different weight to each bar's price. The idea behind VWMA is to place a greater emphasis to the price in times of heavy trading activity.

### Calculation

Volume weighted moving average is calculated as follows:

`VWMA = (Sum of Price * Volume for Lookback Period) / Sum for Volume for Lookback Period`

For simplicity's sake, Wealth-Lab's implementation assumes the Close price as the basis price for calculating VWMA.

**Interpretation**

The VWMA is usually employed together with a comparable SMA. The difference between them shows the effect of volume weighting. Here is just a sample of trading ideas using the VWMA:

- Using a SMA as a benchmark with the same lookback period, the VWMA could be used to confirm trend direction.
- If VWMA moves below SMA, it may mean that the trend lacks volume support. A divergence could be used as a counter-trend signal.
- The VWMA crossing above the SMA may signal a potential bullish trend change.
- A tightening distance between the VWMA and the SMA may suggest an exit point or profit taking.

**Example**

Please refer to

April 2017 Traders' Tip article's code.