Child pages
  • AmortizationCalculation

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin
{div:style=}
Wiki Markup
Div
styledisplay:none

DO

NOT

EDIT

THE

CONTENT

OF

THIS

PAGE

DIRECTLY

(EXCEPT

INSIDE

THE

DIV

BELOW

WITH

ID=DESCRIPTION),

UNLESS

YOU

KNOW

WHAT

YOU'RE

DOING.


THE

STRUCTURE

OF

THE

CONTENT

IS

VITAL

IN

BEING

ABLE

TO

AUTO

UPDATE

THE

CONTENT

THROUGH

THE

DOC

GENERATOR.

\\ \\ Enter additional information related to this



Enter additional information related to this 'class'

inside

the

\

{div}

macro

with

'id=description'

{div} {div:id=description}{div}\\ {table:id=|class=servoy sSummary}{colgroup}{column:width=80px|padding=0px}{column}{column}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=2}Constants Summary{th}{tr}{tbody}{tr}{td}[Number]{td}{td}[#NUMBER_UNLIMITED] The numeric constant used to identify an unlimited number of repeated events.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_ANNUALY] The numeric constant used to identify an annual period.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_BI_ANNUALLY] The numeric constant used to identify a bi\-annual period (twice every year).{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_BI_MONTHLY] The numeric constant used to identify a bi\-monthly period (twice every month).{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_DAILY] The numeric constant used to identify a daily period.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_FOUR_MONTHLY] The numeric constant used to identify a four\-monthly period (once every four months).{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_FOUR_WEEKLY] The numeric constant used to identify a four\-weekly period (once every four weeks).{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_MONTHLY] The numeric constant used to identify a monthly period.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_NONE] The numeric constant used to identify that there is no period.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_QUARTERLY] The numeric constant used to identify a quarterly period (once every three months).{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_TWO_MONTHLY] The numeric constant used to identify a two\-monthly period (once every two months).{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_TWO_WEEKLY] The numeric constant used to identify a two\-weekly period (once every two weeks).{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#PERIOD_WEEKLY] The numeric constant used to identify a weekly period.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#STARTDAY_NORMAL] The numeric constant used to identify that the same start day should be used as the day of the month of the starting date of the event.{td}{tr}{tbody}{table}\\ {table:id=|class=servoy sSummary}{colgroup}{column:width=80px|padding=0px}{column}{column}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=2}Method Summary{th}{tr}{tbody}{tr}{td}[Boolean]{td}{td}[#addCompoundPeriodChange]\(newPeriod, date) Adds a compound period change.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#addLoan]\(amount, date) Adds a loan.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#addLoan]\(amount, firstDate, lastDate, period) Adds a loan.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#addLoan]\(amount, firstDate, lastDate, period, number) Adds a loan.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#addLoan]\(amount, firstDate, lastDate, period, number, startday) Adds a loan.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#addPayment]\(amount, date) Adds a payment.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#addPayment]\(amount, firstDate, lastDate, period) Adds a payment.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#addPayment]\(amount, firstDate, lastDate, period, number) Adds a payment.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#addPayment]\(amount, firstDate, lastDate, period, number, startday) Adds a payment.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#addRateChange]\(newRate, date) Sets a new interest rate.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#calculateAmortizationSchedule]\() Calculates the amortization schedule.{td}{tr}{tbody}{tbody}{tr}{td}[JSDataSet]{td}{td}[#getAmortizationSchedule]\() Gets the amortization schedule as a JSDataSet.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#getError]\() Returns the error that remains when solving for the unknown.{td}{tr}{tbody}{tbody}{tr}{td}[JSDataSet]{td}{td}[#getEvents]\() Returns all the amortization events \- such as rate changes, loan events, payment events, compounding period changes.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#getRestBalance]\() Gets the rest balance after the amortization schedule.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#getUnknown]\() Returns the solveForUnknown value.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#isValidPeriod]\(period) Returns true if the period is valid, or false if the period is not valid.{td}{tr}{tbody}{tbody}{tr}{td}[Number]{td}{td}[#roundMoney]\(amount) Rounds a number up to the nearest cents.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#solveForUnknown]\() Returns true if successful or false if the call failed.{td}{tr}{tbody}{tbody}{tr}{td}void{td}{td}[#sortEvents]\() Sorts the amortization events ascending by date.{td}{tr}{tbody}{table}\\ {table:id=constant|class=servoy sDetail}{colgroup}{column:width=100%|padding=0px}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=1}Constants Details{th}{tr}{tbody:id=NUMBER_UNLIMITED}{tr:id=name}{td}h6.NUMBER_UNLIMITED{td}{tr}{tr:id=des}{td}{div:class=sIndent}The numeric constant used to identify an unlimited number of repeated events.{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Number]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}

Div
iddescription


HTML Table
id
classservoy sSummary
Colgroup Tag
Column
padding0px
width80px

Column

Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Constants Summary
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#NUMBER_UNLIMITED
The numeric constant used to identify an unlimited number of repeated events.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_ANNUALY
The numeric constant used to identify an annual period.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_BI_ANNUALLY
The numeric constant used to identify a bi-annual period (twice every year).
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_BI_MONTHLY
The numeric constant used to identify a bi-monthly period (twice every month).
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_DAILY
The numeric constant used to identify a daily period.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_FOUR_MONTHLY
The numeric constant used to identify a four-monthly period (once every four months).
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_FOUR_WEEKLY
The numeric constant used to identify a four-weekly period (once every four weeks).
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_MONTHLY
The numeric constant used to identify a monthly period.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_NONE
The numeric constant used to identify that there is no period.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_QUARTERLY
The numeric constant used to identify a quarterly period (once every three months).
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_TWO_MONTHLY
The numeric constant used to identify a two-monthly period (once every two months).
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_TWO_WEEKLY
The numeric constant used to identify a two-weekly period (once every two weeks).
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#PERIOD_WEEKLY
The numeric constant used to identify a weekly period.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#STARTDAY_NORMAL
The numeric constant used to identify that the same start day should be used as
the day of the month of the starting date of the event.

HTML Table
id
classservoy sSummary
Colgroup Tag
Column
padding0px
width80px

Column

Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan2
Method Summary
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addCompoundPeriodChange(newPeriod, date)
Adds a compound period change.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addLoan(amount, date)
Adds a loan.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addLoan(amount, firstDate, lastDate, period)
Adds a loan.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addLoan(amount, firstDate, lastDate, period, number)
Adds a loan.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addLoan(amount, firstDate, lastDate, period, number, startday)
Adds a loan.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addPayment(amount, date)
Adds a payment.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addPayment(amount, firstDate, lastDate, period)
Adds a payment.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addPayment(amount, firstDate, lastDate, period, number)
Adds a payment.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addPayment(amount, firstDate, lastDate, period, number, startday)
Adds a payment.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#addRateChange(newRate, date)
Sets a new interest rate.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#calculateAmortizationSchedule()
Calculates the amortization schedule.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
JSDataSet
Table Cell (td)
#getAmortizationSchedule()
Gets the amortization schedule as a JSDataSet.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#getError()
Returns the error that remains when solving for the unknown.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
JSDataSet
Table Cell (td)
#getEvents()
Returns all the amortization events - such as rate changes, loan events, payment events, compounding period changes.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#getRestBalance()
Gets the rest balance after the amortization schedule.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#getUnknown()
Returns the solveForUnknown value.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#isValidPeriod(period)
Returns true if the period is valid, or false if the period is not valid.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Number
Table Cell (td)
#roundMoney(amount)
Rounds a number up to the nearest cents.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
Boolean
Table Cell (td)
#solveForUnknown()
Returns true if successful or false if the call failed.
Table Body (tbody)
Table Row (tr)
Table Cell (td)
void
Table Cell (td)
#sortEvents()
Sorts the amortization events ascending by date.

HTML Table
idconstant
classservoy sDetail
Colgroup Tag
Column
padding0px
width100%

Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan1
Constants Details
Table Body (tbody)
idNUMBER_UNLIMITED
Table Row (tr)
idname
Table Cell (td)
NUMBER_UNLIMITED
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify an unlimited number of repeated events.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_ANNUALY
Table Row (tr)
idname
Table Cell (td)
PERIOD_ANNUALY
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify an annual period.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_BI_ANNUALLY

...

Table Row (tr)

...

id

...

name

...

Table Cell (td)
PERIOD_BI_ANNUALLY

...

Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a bi-annual period (twice every year).
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_BI_MONTHLY

...

Table Row (tr)

...

id

...

name

...

Table Cell (td)
PERIOD_BI_MONTHLY

...

Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a bi-monthly period (twice every month).
TODO: this period is not supported yet.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_DAILY
Table Row (tr)
idname
Table Cell (td)
PERIOD_DAILY
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a daily period.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_FOUR_MONTHLY

...

Table Row (tr)

...

id

...

name

...

Table Cell (td)
PERIOD_FOUR_MONTHLY

...

Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a four-monthly period (once every four months).
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_FOUR_WEEKLY

...

Table Row (tr)

...

id

...

name

...

Table Cell (td)
PERIOD_FOUR_WEEKLY

...

Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a four-weekly period (once every four weeks).
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_MONTHLY
Table Row (tr)
idname
Table Cell (td)
PERIOD_MONTHLY
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a monthly period.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_NONE
Table Row (tr)
idname
Table Cell (td)
PERIOD_NONE
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify that there is no period.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_QUARTERLY
Table Row (tr)
idname
Table Cell (td)
PERIOD_QUARTERLY
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a quarterly period (once every three months).
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_TWO_MONTHLY

...

Table Row (tr)

...

id

...

name

...

Table Cell (td)
PERIOD_TWO_MONTHLY

...

Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a two-monthly period (once every two months).
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_TWO_WEEKLY

...

Table Row (tr)

...

id

...

name

...

Table Cell (td)
PERIOD_TWO_WEEKLY

...

Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a two-weekly period (once every two weeks).
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idPERIOD_WEEKLY
Table Row (tr)
idname
Table Cell (td)
PERIOD_WEEKLY
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify a weekly period.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idSTARTDAY_NORMAL
Table Row (tr)
idname
Table Cell (td)
STARTDAY_NORMAL
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
The numeric constant used to identify that the same start day should be used as
the day of the month of the starting date of the event.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addPayment(500, new Date(2005, 1, 28), null, 
			plugins.amortization.AmortizationCalculation.PERIOD_DAILY, 5, 
			plugins.amortization.AmortizationCalculation.STARTDAY_NORMAL);

var c2 = plugins.amortization.newCalculation();
c2.addPayment(300, new Date(2006, 11, 24), new Date(2006, 12, 24),
			plugins.amortization.AmortizationCalculation.PERIOD_BI_MONTHLY, 
			plugins.amortization.AmortizationCalculation.NUMBER_UNLIMITED, 30);

...

Table Row (tr)
classlastDetailRow
Table Cell (td)


HTML Table
idfunction
classservoy sDetail
Colgroup Tag
Column
padding0px
width100%

Table Row (tr)
styleheight: 30px;
Table Head (th)
colspan1
Method Details
Table Body (tbody)
idaddCompoundPeriodChange-Number_Date
Table Row (tr)
idname
Table Cell (td)
addCompoundPeriodChange
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
addCompoundPeriodChange
Span
(newPeriod, date)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Adds a compound period change.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} newPeriod
{Date} date
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idaddLoan-Number_Date
}{
Table Row (tr)
:
id
=
name
}{td}h6.addLoan{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)
addLoan
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}[
Boolean
]{span}{span:style=
Span
stylefont-weight:
bold;
}
addLoan
{span}{span}\
Span
(amount,
date)
{span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Adds a loan.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} amount \{[Date]} date {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Adds a loan.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} amount
{Date} date
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idaddLoan-Number_Date_Date_Number
}{
Table Row (tr)
:
id
=
name
}{td}h6.addLoan{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)
addLoan
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}[
Boolean
]{span}{span:style=
Span
stylefont-weight:
bold;
}
addLoan
{span}{span}\
Span
(amount,
firstDate,
lastDate,
period)
{span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Adds a loan.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} amount \{[Date]} firstDate \{[Date]} lastDate \{[Number]} period {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Adds a loan.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} amount
{Date} firstDate
{Date} lastDate
{Number} period
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idaddLoan-Number_Date_Date_Number_Number
}{
Table Row (tr)
:
id
=
name
}{td}h6.addLoan{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)
addLoan
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}[
Boolean
]{span}{span:style=
Span
stylefont-weight:
bold;
}
addLoan
{span}{span}\
Span
(amount,
firstDate,
lastDate,
period,
number)
{span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Adds a loan.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} amount \{[Date]} firstDate \{[Date]} lastDate \{[Number]} period \{[Number]} number {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Adds a loan.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} amount
{Date} firstDate
{Date} lastDate
{Number} period
{Number} number
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idaddLoan-Number_Date_Date_Number_Number_Number
}{
Table Row (tr)
:
id
=
name
}{td}h6.addLoan{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)
addLoan
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}[
Boolean
]{span}{span:style=
Span
stylefont-weight:
bold;
}
addLoan
{span}{span}\
Span
(amount,
firstDate,
lastDate,
period,
number,
startday)
{span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Adds a loan.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} amount \{[Date]} firstDate \{[Date]} lastDate \{[Number]} period \{[Number]} number \{[Number]} startday {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Adds a loan.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} amount
{Date} firstDate
{Date} lastDate
{Number} period
{Number} number
{Number} startday
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idaddPayment-Number_Date
}{
Table Row (tr)
:
id
=
name
}{td}h6.addPayment{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)
addPayment
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}[
Boolean
]{span}{span:style=
Span
stylefont-weight:
bold;
}
addPayment
{span}{span}\
Span
(amount,
date)
{span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Adds a payment.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} amount \{[Date]} date {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Adds a payment.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} amount
{Date} date
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idaddPayment-Number_Date_Date_Number
}{
Table Row (tr)
:
id
=
name
}{td}h6.addPayment{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)
addPayment
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}[
Boolean
]{span}{span:style=
Span
stylefont-weight:
bold;
}
addPayment
{span}{span}\
Span
(amount,
firstDate,
lastDate,
period)
{span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Adds a payment.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} amount \{[Date]} firstDate \{[Date]} lastDate \{[Number]} period {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Adds a payment.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} amount
{Date} firstDate
{Date} lastDate
{Number} period
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idaddPayment-Number_Date_Date_Number_Number
}{
Table Row (tr)
:
id
=
name
}{td}h6.addPayment{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)
addPayment
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}[
Boolean
]{span}{span:style=
Span
stylefont-weight:
bold;
}
addPayment
{span}{span}\
Span
(amount,
firstDate,
lastDate,
period,
number)
{span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Adds a payment.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} amount \{[Date]} firstDate \{[Date]} lastDate \{[Number]} period \{[Number]} number {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Adds a payment.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} amount
{Date} firstDate
{Date} lastDate
{Number} period
{Number} number
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idaddPayment-Number_Date_Date_Number_Number_Number
}{
Table Row (tr)
:
id
=
name
}{td}h6.addPayment{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)
addPayment
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}[
Boolean
]{span}{span:style=
Span
stylefont-weight:
bold;
}
addPayment
{span}{span}\
Span
(amount,
firstDate,
lastDate,
period,
number,
startday)
{span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Adds a payment.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} amount \{[Date]} firstDate \{[Date]} lastDate \{[Number]} period \{[Number]} number \{[Number]} startday {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Adds a payment.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} amount
{Date} firstDate
{Date} lastDate
{Number} period
{Number} number
{Number} startday
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idaddRateChange-Number_Date
}{
Table Row (tr)
:
id
=
name
}{td}h6.addRateChange{td}{tr}{tr:id=sig}{td}{span:style=
Table Cell (td)
addRateChange
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right:
5px;
}[
Boolean
]{span}{span:style=
Span
stylefont-weight:
bold;
}
addRateChange
{span}{span}\
Span
(newRate,
date)
{span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Sets a new interest rate.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} newRate \{[Date]} date {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Sets a new interest rate.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} newRate
{Date} date
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
c.addRateChange(r, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
c.addPayment(500, new Date(2005, 1, 28), null, 12, 5, 31);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=calculateAmortizationSchedule}{tr:id=name}{td}h6.calculateAmortizationSchedule{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[Boolean]{span}{span:style=font-weight: bold;}calculateAmortizationSchedule{span}{span}\(){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Calculates the amortization schedule.{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idcalculateAmortizationSchedule
Table Row (tr)
idname
Table Cell (td)
calculateAmortizationSchedule
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
calculateAmortizationSchedule
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Calculates the amortization schedule.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

plugins.amortization.calculateAmortizationSchedule();
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getAmortizationSchedule}{tr:id=name}{td}h6.getAmortizationSchedule{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[JSDataSet]{span}{span:style=font-weight: bold;}getAmortizationSchedule{span}{span}\(){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Gets the amortization schedule as a JSDataSet.{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[JSDataSet]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idgetAmortizationSchedule
Table Row (tr)
idname
Table Cell (td)
getAmortizationSchedule
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
JSDataSet
Span
stylefont-weight: bold;
getAmortizationSchedule
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Gets the amortization schedule as a JSDataSet.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
JSDataSet
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

plugins.amortization.getAmortizationSchedule();
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getError}{tr:id=name}{td}h6.getError{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[Number]{span}{span:style=font-weight: bold;}getError{span}{span}\(){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Returns the error that remains when solving for the unknown. Please note that the error should be less or equal to 1E\-8 \- otherwise, the solveForUnknown value is incorrect.{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Number]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idgetError
Table Row (tr)
idname
Table Cell (td)
getError
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
getError
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns the error that remains when solving for the unknown.
Please note that the error should be less or equal to 1E-8 - otherwise, the solveForUnknown value is incorrect.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var c = plugins.amortization.newCalculation();
// sets the rate to -1 for unknown.
c.addRateChange(-1, new Date(2005, 0, 1));
c.addCompoundPeriodChange(12, new Date(2005, 0, 1));
c.addLoan(2000, new Date(2005, 0, 1));
var lastDate = null;
var period = 12;
var number_count = 5;
var startday = 31;
c.addPayment(500, new Date(2005, 1, 28), lastDate, period,number_count, startday);
// solves for the interest rate.
c.solveForUnknown();
// gets the interest rate and the error in the calculation.
// which should be small (otherwise the calculation did
// not converge for some reason.
var r = c.getUnknown();
var e = c.getError();
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getEvents}{tr:id=name}{td}h6.getEvents{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[JSDataSet]{span}{span:style=font-weight: bold;}getEvents{span}{span}\(){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Returns all the amortization events \- such as rate changes, loan events, payment events, compounding period changes.{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[JSDataSet]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idgetEvents
Table Row (tr)
idname
Table Cell (td)
getEvents
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
JSDataSet
Span
stylefont-weight: bold;
getEvents
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns all the amortization events - such as rate changes, loan events, payment events, compounding period changes.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
JSDataSet
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

plugins.amortization.getEvents();
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getRestBalance}{tr:id=name}{td}h6.getRestBalance{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[Number]{span}{span:style=font-weight: bold;}getRestBalance{span}{span}\(){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Gets the rest balance after the amortization schedule.{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Number]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idgetRestBalance
Table Row (tr)
idname
Table Cell (td)
getRestBalance
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
getRestBalance
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Gets the rest balance after the amortization schedule.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var rb = plugins.amortization.getRestBalance();
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getUnknown}{tr:id=name}{td}h6.getUnknown{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[Number]{span}{span:style=font-weight: bold;}getUnknown{span}{span}\(){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Returns the solveForUnknown value.{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Number]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idgetUnknown
Table Row (tr)
idname
Table Cell (td)
getUnknown
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
getUnknown
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns the solveForUnknown value.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

plugins.amortization.getUnknown();
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=isValidPeriod-Number}{tr:id=name}{td}h6.isValidPeriod{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[Boolean]{span}{span:style=font-weight: bold;}isValidPeriod{span}{span}\(period){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Returns true if the period is valid, or false if the period is not valid.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} period {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idisValidPeriod-Number
Table Row (tr)
idname
Table Cell (td)
isValidPeriod
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
isValidPeriod
Span
(period)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns true if the period is valid, or false if the period is not valid.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} period
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

var v_period = plugins.amortization.isValidPeriod(12);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=roundMoney-Number}{tr:id=name}{td}h6.roundMoney{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[Number]{span}{span:style=font-weight: bold;}roundMoney{span}{span}\(amount){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Rounds a number up to the nearest cents.{div}{td}{tr}{tr:id=prs}{td}*Parameters*\\{div:class=sIndent}\{[Number]} amount {div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Number]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idroundMoney-Number
Table Row (tr)
idname
Table Cell (td)
roundMoney
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Number
Span
stylefont-weight: bold;
roundMoney
Span
(amount)
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Rounds a number up to the nearest cents.
Table Row (tr)
idprs
Table Cell (td)
Parameters
Div
classsIndent
{Number} amount
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Number
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

//rounds the number up to 34.35
var rm = plugins.amortization.roundMoney(34.349384);
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=solveForUnknown}{tr:id=name}{td}h6.solveForUnknown{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}[Boolean]{span}{span:style=font-weight: bold;}solveForUnknown{span}{span}\(){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Returns true if successful or false if the call failed.{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}[Boolean]{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}

Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idsolveForUnknown
Table Row (tr)
idname
Table Cell (td)
solveForUnknown
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
Boolean
Span
stylefont-weight: bold;
solveForUnknown
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Returns true if successful or false if the call failed.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
Boolean
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

plugins.amortization.solveForUnknown();
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=sortEvents}{tr:id=name}{td}h6.sortEvents{td}{tr}{tr:id=sig}{td}{span:style=margin-right: 5px;}void{span}{span:style=font-weight: bold;}sortEvents{span}{span}\(){span}{td}{tr}{tr:id=des}{td}{div:class=sIndent}Sorts the amortization events ascending by date.{div}{td}{tr}{tr:id=ret}{td}*Returns*\\{div:class=sIndent}void{div}{td}{tr}{tr:id=sam}{td}*Sample*\\{div:class=sIndent}{code:language=javascript}
Table Row (tr)
classlastDetailRow
Table Cell (td)

Table Body (tbody)
idsortEvents
Table Row (tr)
idname
Table Cell (td)
sortEvents
Table Row (tr)
idsig
Table Cell (td)
Span
stylemargin-right: 5px;
void
Span
stylefont-weight: bold;
sortEvents
Span
()
Table Row (tr)
iddes
Table Cell (td)
Div
classsIndent
Sorts the amortization events ascending by date.
Table Row (tr)
idret
Table Cell (td)
Returns
Div
classsIndent
void
Table Row (tr)
idsam
Table Cell (td)
Sample
Div
classsIndent
Code Block
languagejavascript

plugins.amortization.sortEvents();
{code}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{table}
Table Row (tr)
classlastDetailRow
Table Cell (td)