FVSCHEDULE
function FVSCHEDULE(arg1: any = null, arg2: any = null): number | string | boolean
Description
Returns the future value of an initial principal after applying a series of compound interest rates.
Parameters
- arg1
any
null Is the present value.
- arg2
any
null Is an array of interest rates to apply.
Returns
number | string | boolean
Try It
var oWorksheet = Api.GetActiveSheet();
var oFunction = Api.GetWorksheetFunction();
oWorksheet.GetRange("A1").SetValue("Principal");
oWorksheet.GetRange("B1").SetValue(100);
oWorksheet.GetRange("A2").SetValue("Rate 1");
oWorksheet.GetRange("B2").SetValue(0.03);
oWorksheet.GetRange("A3").SetValue("Rate 2");
oWorksheet.GetRange("B3").SetValue(0.05);
oWorksheet.GetRange("A4").SetValue("Rate 3");
oWorksheet.GetRange("B4").SetValue(0.1);
var oRange = oWorksheet.GetRange("B2:B4");
oWorksheet.GetRange("B5").SetValue(oFunction.FVSCHEDULE(100, oRange));