  Credit Suisse First Boston (CSFB) launched in 1997 the model CreditRisk+
which aims at calculating the loss distribution of a credit portfolio on the
basis of a methodology from actuarial mathematics. Knowing the loss
distribution, it is possible to determine quantile-based values-at-risk (VaRs)
for the portfolio. An open question is how to attribute fair VaR contributions
to the credits or loans forming the portfolio. One approach is to define the
contributions as certain conditional expectations. We develop an algorithm for
the calculations involved in this approach. This algorithm can be adapted for
computing the contributions to the portfolio Expected Shortfall (ES).
  Key words: CreditRisk+; Value-at-Risk (VaR); risk contribution; conditional
expectation.
