public class FinancialCalculator extends Object
| Modifier and Type | Field and Description |
|---|---|
static boolean |
DEBUG |
| Constructor and Description |
|---|
FinancialCalculator() |
| Modifier and Type | Method and Description |
|---|---|
protected static Ptg |
calcAccrint(Ptg[] operands)
ACCRINT - Returns the accrued interest for a security that pays periodic
interest Analysis Pak function Issue is the security's issue date.
|
protected static Ptg |
calcAccrintm(Ptg[] operands)
ACCRINTM Returns the accrued interest for a security that pays interest
at maturity Analysis Pak function
Issue is the security's issue date.
|
protected static Ptg |
calcAmordegrc(Ptg[] operands)
AMORDEGRC Returns the depreciation for each accounting period
|
protected static Ptg |
calcAmorlinc(Ptg[] operands)
AMORLINC Returns the depreciation for each accounting period
|
protected static Ptg |
calcCoupDayBS(Ptg[] operands)
COUPDAYBS --
Returns the number of days from the beginning of the coupon period to the
settlement date Settlement is the security's settlement date.
|
protected static Ptg |
calcCoupDays(Ptg[] operands)
COUPDAYS Returns the number of days in the coupon period that contains
the settlement date Settlement is the security's settlement date.
|
protected static Ptg |
calcCoupDaysNC(Ptg[] operands)
COUPDAYSNC - Returns the number of days from the settlement date to the
next coupon date
Settlement is the security's settlement date.
|
protected static Ptg |
calcCoupNCD(Ptg[] operands)
COUPNCD Returns the next coupon date after the settlement date Returns a
number that represents the next coupon date after the settlement date.
|
protected static Ptg |
calcCoupNum(Ptg[] operands)
COUPNUM Returns the number of coupons payable between the settlement date
and maturity date Settlement is the security's settlement date.
|
protected static Ptg |
calcCoupPCD(Ptg[] operands)
COUPPCD Returns the previous coupon date before the settlement date
|
protected static Ptg |
calcCumIPmt(Ptg[] operands)
CUMIPMT Returns the cumulative interest paid between two periods
CUMIPMT(rate,nper,pv,start_period,end_period,type) All parameters are
require Rate is the interest rate.
|
protected static Ptg |
calcCumPrinc(Ptg[] operands)
CUMPRINC Returns the cumulative principal paid on a loan between
start_period and end_period.
|
protected static Ptg |
calcDB(Ptg[] operands)
DB Returns the depreciation of an asset for a specified period using the
fixed-declining balance method
DB(cost,salvage,life,period,month)
Cost is the initial cost of the asset.
|
protected static Ptg |
calcDDB(Ptg[] operands)
DDB Returns the depreciation of an asset for a spcified period using the
double-declining balance method or some other method you specify
DDB(cost,salvage,life,period,factor)
Cost is the initial cost of the asset.
|
protected static Ptg |
calcDISC(Ptg[] operands)
DISC Returns the discount rate for a security
Settlement is the security's settlement date.
|
protected static Ptg |
calcDollarDE(Ptg[] operands)
DOLLARDE Converts a dollar price, expressed as a fraction, into a dollar
price, expressed as a decimal number Fractional_dollar is a number
expressed as a fraction.
|
protected static Ptg |
calcDollarFR(Ptg[] operands)
DOLLARFR Converts a dollar price, expressed as a decimal number, into a
dollar price, expressed as a fraction Decimal_dollar is a decimal number.
|
protected static Ptg |
calcDURATION(Ptg[] operands)
DURATION Returns the annual duration of a security with periodic interest
payments
DURATION(settlement,maturity,coupon,yld,frequency,basis)
Settlement is the security's settlement date.
|
protected static Ptg |
calcEffect(Ptg[] operands)
EFFECT Returns the effective annual interest rate Nominal_rate is the
nominal interest rate.
|
protected static Ptg |
calcFV(Ptg[] operands)
FV Returns the future value of an investment FV(rate,nper,pmt,pv,type)
Rate is the interest rate per period.
|
protected static Ptg |
calcFVSCHEDULE(Ptg[] operands)
FVSCHEDULE Returns the future value of an initial principal after
applying a series of compound interest rates
|
protected static Ptg |
calcINTRATE(Ptg[] operands)
INTRATE Returns the interest rate for a fully invested security
|
protected static Ptg |
calcIPMT(Ptg[] operands)
IPMT Returns the interest payment for an investment for a given period.
|
protected static Ptg |
calcIRR(Ptg[] operands)
IRR Returns the internal rate of return for a series of cash flows
Returns the internal rate of return for a series of cash flows
represented by the numbers in values.
|
protected static Ptg |
calcISPMT(Ptg[] operands)
ISPMT Calculates the interest paid during a specific period of an
investment.
|
protected static Ptg |
calcMDURATION(Ptg[] operands)
MDURATION Returns the Macauley modified duration for a security with an
assumed par value of $100
DURATION(settlement,maturity,coupon,yld,frequency,basis) Settlement is
the security's settlement date.
|
protected static Ptg |
calcMIRR(Ptg[] operands)
MIRR Returns the internal rate of return where positive and negative cash
flows are financed at different rates
MIRR(values,finance_rate,reinvest_rate)
Values is an array or a reference to cells that contain numbers.
|
protected static Ptg |
calcNominal(Ptg[] operands)
NOMINAL Returns the annual nominal interest rate
|
protected static Ptg |
calcNPER(Ptg[] operands)
NPER Returns the number of periods for an investment NPER(rate, pmt, pv,
fv, type)
Rate is the interest rate per period.
|
protected static Ptg |
calcNPV(Ptg[] operands)
NPV(rate,value1,value2, ...) Calculates the net present value of an
investment by using a discount rate and a series of future payments
(negative values) and income (positive values).
|
protected static Ptg |
calcODDFPRICE(Ptg[] operands)
ODDFPRICE Returns the price per $100 face value of a security with an odd
first period
ODDFPRICE(settlement,maturity,issue,first_coupon,rate,yld,redemption,frequency,basis)
|
protected static Ptg |
calcODDFYIELD(Ptg[] operands) |
protected static Ptg |
calcODDLPRICE(Ptg[] operands) |
protected static Ptg |
calcODDLYIELD(Ptg[] operands) |
protected static Ptg |
calcPmt(Ptg[] operands)
PMT Returns the periodic payment for an annuity
pmt= - (fv + (1+rate)**nper * pv) * rate / ( ( (1+rate)**nper - 1 ) *
(1+rate*type) )
if fv or type are omitted they should be treated as 0 values.
|
protected static Ptg |
calcPPMT(Ptg[] operands)
PPMT Returns the payment on the principal for an investment for a given
period PPMT(rate,per,nper,pv,fv,type) Rate is the interest rate per
period.
|
protected static Ptg |
calcPRICE(Ptg[] operands)
PRICE Returns the price per $100 face value of a security that pays
periodic interest
PRICE(settlement,maturity,rate,yld,redemption,frequency,basis) Settlement
is the security's settlement date.
|
protected static Ptg |
calcPRICEDISC(Ptg[] operands)
PRICEDISC Returns the price per $100 face value of a discounted security
PRICEDISC(settlement,maturity,discount,redemption,frequency,basis)
Settlement is the security's settlement date.
|
protected static Ptg |
calcPRICEMAT(Ptg[] operands)
PRICEMAT Returns the price per $100 face value of a security that pays
interest at maturity
|
protected static Ptg |
calcPV(Ptg[] operands)
PV(rate,nper,pmt,fv,type) Returns the present value of an investment Rate
is the interest rate per period.
|
protected static Ptg |
calcRate(Ptg[] operands)
RATE Returns the interest rate per period of an annuity.
|
protected static Ptg |
calcReceived(Ptg[] operands)
RECEIVED Returns the amount received at maturity for a fully invested
security
|
protected static Ptg |
calcSLN(Ptg[] operands)
SLN Returns the straight-line depreciation of an asset for one period
SLN(cost,salvage,life) Cost is the initial cost of the asset.
|
protected static Ptg |
calcSYD(Ptg[] operands)
SYD Returns the sum-of-years' digits depreciation of an asset for a
specified period SYD(cost,salvage,life,per) Cost is the initial cost of
the asset.
|
protected static Ptg |
calcTBillEq(Ptg[] operands)
TBILLEQ Returns the bond-equivalent yield for a Treasury bill Settlement
is the Treasury bill's settlement date.
|
protected static Ptg |
calcTBillPrice(Ptg[] operands)
TBILLPRICE Returns the price per $100 face value for a Treasury bill
|
protected static Ptg |
calcTBillYield(Ptg[] operands)
TBILLYIELD Returns the yield for a Treasury bill
VDB Returns the depreciation of an asset for a specified or partial
period using a declining balance method
|
protected static Ptg |
calcVDB(Ptg[] operands)
VDB
Returns the depreciation of an asset for any period you specify,
including partial periods, using the double-declining balance method or
some other method you specify.
|
protected static Ptg |
calcXIRR(Ptg[] operands)
XIRR Returns the internal rate of return for a schedule of cash flows
that is not necessarily periodic
|
protected static Ptg |
calcXNPV(Ptg[] operands)
XNPV Returns the net present value for a schedule of cash flows that is
not necessarily periodic
|
protected static Ptg |
calcYIELD(Ptg[] operands)
YIELD Returns the yield on a security that pays periodic interest
YIELD(settlement,maturity,rate,pr,redemption,frequency,basis) Settlement
is the security's settlement date.
|
protected static Ptg |
calcYieldDisc(Ptg[] operands)
YIELDDISC Returns the annual yield for a discounted security.
|
protected static Ptg |
calcYieldMat(Ptg[] operands)
YIELDMAT Returns the annual yield of a security that pays interest at
maturity
|
static boolean |
isLeapYear(int year) |
protected static Ptg calcAccrint(Ptg[] operands) throws FunctionNotSupportedException
FunctionNotSupportedExceptionprotected static Ptg calcAccrintm(Ptg[] operands)
protected static Ptg calcAmordegrc(Ptg[] operands)
protected static Ptg calcAmorlinc(Ptg[] operands)
protected static Ptg calcCoupDayBS(Ptg[] operands)
protected static Ptg calcCoupDays(Ptg[] operands)
protected static Ptg calcCoupDaysNC(Ptg[] operands)
protected static Ptg calcCoupNCD(Ptg[] operands)
protected static Ptg calcCoupNum(Ptg[] operands)
protected static Ptg calcCoupPCD(Ptg[] operands)
protected static Ptg calcCumIPmt(Ptg[] operands)
protected static Ptg calcCumPrinc(Ptg[] operands)
protected static Ptg calcDB(Ptg[] operands)
protected static Ptg calcDDB(Ptg[] operands)
protected static Ptg calcDISC(Ptg[] operands)
protected static Ptg calcDollarDE(Ptg[] operands)
protected static Ptg calcDollarFR(Ptg[] operands)
protected static Ptg calcDURATION(Ptg[] operands)
protected static Ptg calcEffect(Ptg[] operands)
protected static Ptg calcFV(Ptg[] operands)
protected static Ptg calcFVSCHEDULE(Ptg[] operands)
protected static Ptg calcINTRATE(Ptg[] operands)
protected static Ptg calcIPMT(Ptg[] operands)
protected static Ptg calcIRR(Ptg[] operands)
protected static Ptg calcISPMT(Ptg[] operands)
protected static Ptg calcMDURATION(Ptg[] operands)
protected static Ptg calcMIRR(Ptg[] operands)
protected static Ptg calcNominal(Ptg[] operands)
protected static Ptg calcNPER(Ptg[] operands)
protected static Ptg calcNPV(Ptg[] operands)
protected static Ptg calcODDFPRICE(Ptg[] operands) throws FunctionNotSupportedException
FunctionNotSupportedExceptionprotected static Ptg calcODDFYIELD(Ptg[] operands) throws FunctionNotSupportedException
FunctionNotSupportedExceptionprotected static Ptg calcODDLPRICE(Ptg[] operands) throws FunctionNotSupportedException
FunctionNotSupportedExceptionprotected static Ptg calcODDLYIELD(Ptg[] operands) throws FunctionNotSupportedException
FunctionNotSupportedExceptionprotected static Ptg calcPmt(Ptg[] operands)
protected static Ptg calcPPMT(Ptg[] operands)
protected static Ptg calcPRICE(Ptg[] operands)
protected static Ptg calcPRICEDISC(Ptg[] operands)
protected static Ptg calcPRICEMAT(Ptg[] operands)
protected static Ptg calcPV(Ptg[] operands)
protected static Ptg calcRate(Ptg[] operands)
protected static Ptg calcReceived(Ptg[] operands)
protected static Ptg calcSLN(Ptg[] operands)
protected static Ptg calcSYD(Ptg[] operands)
protected static Ptg calcTBillEq(Ptg[] operands)
protected static Ptg calcTBillPrice(Ptg[] operands)
protected static Ptg calcTBillYield(Ptg[] operands)
protected static Ptg calcVDB(Ptg[] operands)
protected static Ptg calcXIRR(Ptg[] operands)
protected static Ptg calcXNPV(Ptg[] operands)
protected static Ptg calcYIELD(Ptg[] operands)
protected static Ptg calcYieldDisc(Ptg[] operands)
protected static Ptg calcYieldMat(Ptg[] operands)
public static boolean isLeapYear(int year)
Copyright © 2002–2019 Starter Inc.. All rights reserved.