Calculating the average traded price of a stock over a given period involves finding the weighted average price, often referred to as the Volume Weighted Average Price (VWAP). VWAP is a more accurate reflection of the average price at which a stock is traded throughout the day because it accounts for both price and volume of each transaction. The formula for VWAP is:
[ \text{VWAP} = \frac{\sum (\text{Price} \times \text{Volume})}{\sum \text{Volume}} ]
Here’s how you can calculate it:

Collect Price and Volume Data: For each trade of the stock, record the price at which it was traded and the number of shares traded at that price.

Calculate Price x Volume for Each Trade: Multiply the price by the volume for each trade.

Sum Up Price x Volume: Add together all the Price x Volume figures you calculated.

Sum Up Total Volume: Add together the volume of all the trades.

Divide to Get VWAP: Divide the sum of Price x Volume by the sum of Volume.
For example, suppose there are three trades of a stock during a day:
 Trade 1: 100 shares at $10
 Trade 2: 200 shares at $11
 Trade 3: 300 shares at $12
The VWAP would be calculated as:
[ \text{VWAP} = \frac{(100 \times 10) + (200 \times 11) + (300 \times 12)}{100 + 200 + 300} ] [ \text{VWAP} = \frac{1000 + 2200 + 3600}{600} ] [ \text{VWAP} = \frac{6800}{600} ] [ \text{VWAP} = 11.33 ]
So, the average traded price of the stock, as measured by VWAP, would be $11.33. This method provides a more accurate picture of the stock’s average price, especially in markets with large fluctuations in volume and price throughout the trading period.