跳到主要内容

PPMT

Returns the payment on the principal for a given investment based on periodic, constant payments and a constant interest rate.

Syntax

expression.PPMT(arg1, arg2, arg3, arg4, arg5, arg6);

expression - A variable that represents a ApiWorksheetFunction class.

Parameters

NameRequired/OptionalData typeDefaultDescription
arg1RequiredApiRange | ApiName | numberThe interest rate per period. For example, use 6%/4 for quarterly payments at 6% APR.
arg2RequiredApiRange | ApiName | numberThe period for which the principal payment will be returned. It must be in the range from 1 to to the total number of payment periods.
arg3RequiredApiRange | ApiName | numberThe total number of payment periods in an investment.
arg4RequiredApiRange | ApiName | numberThe present value: the total amount that a series of future payments is worth now.
arg5OptionalApiRange | ApiName | numberThe future value, or cash balance which will be attained after the last payment is made.
arg6OptionalApiRange | ApiName | numberA logical value: payment at the beginning of the period = 1; payment at the end of the period = 0 or omitted.

Returns

number

Example

let worksheet = Api.GetActiveSheet();
let func = Api.GetWorksheetFunction();
worksheet.GetRange("A1").SetValue(func.PPMT(0.1/12, 1, 2*12, 2000, 0));