Skip to content

Modern Finance RateConvertCompounding

Paul Squires edited this page Oct 19, 2026 · 4 revisions

Home › Finance › Finance › RateConvertCompounding

RateConvertCompounding

Restates a quoted annual rate for a different compounding frequency.

Syntax

RateConvertCompounding( nominalAnnual, fromCompounding, toCompounding )

Examples

#import "std/money"
using money

'' Restate a quoted rate under a different compounding frequency, so two
'' quotes can actually be compared.  It goes through the effective annual
'' rate, which is the only common ground the two have.
dim as Decimal j = DecimalParse( "0.0595" ).Value( )

'' 5.95% semi-annual is a LOWER monthly-quoted rate for the same return.
print RateConvertCompounding( j, COMPOUND_SEMIANNUAL, COMPOUND_MONTHLY ).Value( ).ToStringFixed( 8 )

'' Converting to the same frequency changes nothing.
print ( RateConvertCompounding( j, COMPOUND_MONTHLY, COMPOUND_MONTHLY ).Value( ) = j )  '' true

Library: Finance
Category: Finance
Documented under: Nothing Becomes A Keyword
Source: pkg/std/money/fincore.tiko in the tiko repository.

Clone this wiki locally