WAM is calculated by computing the percentage value of each mortgage or debt instrument in the portfolio. The number of months or years until the bond's maturity is multiplied by each percentage, and the sum of the subtotals equals the weighted average maturity of the bonds in the portfolio.