Introduced in release: 1.0 Component: Generic Purpose:
Calculates either a dollar price given a yield to maturity or a yield to maturity given a dollar price for an at-maturity security. It then does a recalculation using a given increase and decrease yield or price increment.
Notes:
The maturity date used by this routine can be a maturity/redemption date.
Results:
This routine returns the three calculated price/yields, the two changes due to the increment adjustments, and the average change. All results are calculated using the industry standard rules or generally accepted practices. The variable calc_mid contains the calculated dollar price to maturity per 100 of maturity value or yield to maturity as a percent, both accurate to as many places as supported by a double precision value. The variable calc_up contains the calculated dollar price or yield to maturity from the given plus the increment change. The variable calc_down contains the calculated dollar price or yield to redemption from the given minus the increment change. The variable calc_average_chg contains the average change [(up change + down change)/2].
Error Conditions:
Returned values should be ignored for a non-zero status. See Errors.