Skip to main content

Average Price

The average share price is a calculation method designed to figure out the mean cost involved in buying a set of stocks traded on the stock market. It's a strategy that investors often use when they acquire shares from the same company at different points in time and at varying prices. The goal here is to determine the average purchase price, which can help level out the ups and downs in stock prices over time.

To work out the average price, you add up the total amount you've paid for all the shares and then divide it by the total number of shares you've bought. For example, if an investor bought 100 shares of a company in two transactions — first 20 shares at R$10 each and then another 80 shares at R$12 each — the average acquisition price would be calculated like this:

xˉ=i=1nwixii=1nwi=(20×10R$/share)+(80×12R$/share)100=11.60R$/share\bar{x} = \frac{\sum_{i=1}^{n} w_i x_i}{\sum_{i=1}^{n} w_i} = \frac{(20 \times 10 \,\text{R\$/share}) + (80 \times 12\,\text{R\$/share})}{100} = 11.60\,\text{R\$/share}

Where xˉ\bar{x} is the average price, wiw_i is the quantity of shares and xix_i the price paid on each share, from i=1i=1 to nn, where nn is the number of transactions.

So, in this scenario, the average acquisition price for the 100 shares turns out to be R$11.60 per share.

To get the average price, you can visit the Average Price endpoint. This link provides the average price for each position in your portfolio.