*(This content was originally published as an Action Alerts PLUS Alert on Jan. 14, 2016. Stock prices, shares held and portfolio positions may have changed.)*

As discussed on our Member's Only Call (video replay available on the top right of the Action Alerts PLUS landing page), we want to do a more thorough job of educating our subscribers on concepts that may sometimes be overlooked in our analysis. One common question that we received prior to the call was in regards to cost basis. While we briefly went over this concept on the call, we also wanted to provide a more detailed Alert for subscribers to have for reference down the line. While this may be basic for some subscribers, we believe this is a good reference tool to have at your disposal at any time.

When we speak about "our cost basis on a stock," what we are really referring to is the weighted average cost we have paid for all shares of a particular position. The weighted average cost accounts for variables such as stock price, amount of shares purchased at a given time and average commission paid. When we add additional shares to the position, or when we trim the position by selling shares, the cost basis is affected by these changes.

The best way to run through the detail behind calculating cost basis is to provide an example. Take this situation:

-- We purchase 100 shares of stock "XYZ" at $10 per share on Day 1 for a total commission of $7. At this point, our cost basis on stock XYZ is $10.07 per share ($10 per share + [$7 in commission divided by $100 shares] = $10.07). We divide the commission by the amount of shares in order to get the fee on a per-share basis.

-- On Day 2, we purchase 50 more shares of stock XYZ at $9 for a total commission of $7. On these 50 shares bought on Day 2, our cost basis would be $9.14 per share ($9 per share + [$7 in commission divided by 50 shares] = $9.14). However, we now need to incorporate the cost of these 50 shares into the cost of our overall position, which is now 150 shares. In order to do this, we need to take a weighted average, which is an average calculated based on the relative importance of each component (in this case, the components are our two sets of trades). Thus, our overall cost basis at this point would be $9.76 per share. This is calculated with this equation: ([$10.07 x 100 shares = $1,007] + [$9.14 x 50 shares = $457]) / 150 shares = $9.76, where the numerator of the equation (which equals $1,464 when added together) is the total cost of the position and the denominator is the total amount of shares in the position.

-- In order to continue to calculate the cost basis, each time new shares are added to the position, we follow the same steps to calculate the cost basis; i.e., we take the total cost of the position (which is calculated by adding the costs of each trade, including commission) and divide that by the overall amount of shares that now make up the position.

-- The same logic applies if we sell a portion of the position. For example, if on Day 3 we sell 120 shares of stock XYZ, our new cost basis on the stock becomes $9.14 per share. We get to this number because the first 100 shares sold were bought at an average of $10.07 (see above) and the remaining 20 shares were bought at an average of $9.14 (see above). What we are left with is 30 shares (out of the original 150) that were bought at an average of $9.14 per share.

So, that is a basic rundown of cost basis. Please see the image below, which better illustrates the calculations. We hope this is educational and will help subscribers in the future when we refer to the concept in trades and analysis.