The valuation of interest rate hedging with credit risk (loan, bond, etc.) is done by. updating the timing of cash flows of the instrument with the discount factors applicable to government bonds and by adding a liquidity premium, that is to say, an estimate of the cost of negotiating the instrument for Unsecured Loans in NZ.
and finally adding an estimate of the expected risk of default by the borrower for the loan. To evaluate this, we proceed by comparison with the debt or, increasingly, credit default swaps issuers with the same rating. The difference in yield to maturity that must shift the curve zero-coupon government bond rate to arrive at the price recorded on the market, is commonly called spread rate of the instrument and is used to compare the relative values of different rate instruments.
Before the widespread use of computers with high computing power, we simply used the difference between the yield to maturity of the instrument and that of a neighboring government bond length, but this method is rather imprecise and tends to disappear gradually.