| Type: | Package | 
| Title: | Capital Budgeting Analysis, Annuity Loan Calculations and Amortization Schedules | 
| Version: | 1.3.0 | 
| Author: | John T. Buynak | 
| Maintainer: | John T. Buynak <jbuynak94@gmail.com> | 
| Description: | Provides Capital Budgeting Analysis functionality and the essential Annuity loan functions. Also computes Loan Amortization Schedules including schedules with irregular payments. | 
| License: | GPL-3 | 
| Encoding: | UTF-8 | 
| LazyData: | true | 
| RoxygenNote: | 6.1.1 | 
| Suggests: | knitr, rmarkdown | 
| VignetteBuilder: | knitr | 
| NeedsCompilation: | no | 
| Packaged: | 2019-11-22 23:51:51 UTC; John Buynak | 
| Repository: | CRAN | 
| Date/Publication: | 2019-11-23 05:30:02 UTC | 
Annuity Loan Calculation
Description
Calculates the payment, present value, future value, rate, or the number of periods
Usage
annuity(type = c("pv", "fv", "pmt", "nper", "rate"), pv, fv = 0, pmt,
  n, r, end = TRUE)
Arguments
| type | Loan parameter to return. ("pv", "fv", "pmt", "nper", "rate") | 
| pv | Present Value | 
| fv | Future Value | 
| pmt | Periodic Payment | 
| n | Number of Periods | 
| r | Rate | 
| end | Logical, set to TRUE. If FALSE, payments are made at the beginning the period. | 
Value
Returns the selected Annuity Loan Parameter
Examples
annuity(type = "pmt", pv = -2000, fv = 0, n  = 4 * 12, r = 0.06/12, end = TRUE)
Effective Annual Rate
Description
Effective Annual Rate
Usage
ear(apr, n, p = 5)
Arguments
| apr | Annual Rate (Nominal Interest Rate) | 
| n | Number of compounds in a year | 
| p | Calculates the EAR to the (1/10^p) decimal place | 
Value
Effective Annual Rate
Examples
ear(apr= 0.05, n = 12)
Future Value
Description
Calculates the Future Value given a Present Value
Usage
fv(pv, r, n)
Arguments
| pv | Present Value | 
| r | Discount Rate | 
| n | Number of Compounding Periods | 
Value
Returns the Future Value
Examples
fv(5000, 0.08/12, 5*12)
Geometric Mean Return
Description
Geometric Mean Return
Usage
geometric(c)
Arguments
| c | Periodic returns in decimal form | 
Value
Returns the Geometric Mean Return
Examples
geometric(c(0.05, 0.02, -0.03, 0.09, -0.02))
Interest Payment
Description
Calculates the interest portion of the payment in period "x"
Usage
ipmt(pv, fv = 0, n, r, x, end = TRUE)
Arguments
| pv | Present Value | 
| fv | Future Value | 
| n | Number of Periods | 
| r | Rate | 
| x | Period in which to calculate the interest portion of the payment | 
| end | If FALSE, payments are made at the beginning of the period | 
Value
Returns the Interest Portion of the Payment in Period "x"
Examples
ipmt(pv = 20000, fv = 0, n = 5 * 12, r = 0.05/12, x = 12, end = TRUE)
Amortization Schedule With Irregular Payments
Description
Creates an amortization schedule of a loan with irregular payments and withdrawals
Usage
irregular(payments, dates, apr, pv, info = TRUE)
Arguments
| payments | Vector of payments, the first payment must be 0 | 
| dates | Vector of dates, the first date is the date of origination | 
| apr | Annual rate | 
| pv | Present Value | 
| info | Logical, if set to 'TRUE' information about the dataframe arrangement will be printed | 
Value
Returns the irregular Amortization Schedule in a Dataframe
Examples
irregular(payments = c(0, 200, -100), dates = c("2019-01-01", "2019-02-08", "2019-03-20"),
apr = 0.05, pv = 2000, info = FALSE)
Principal Payment
Description
Calculates the principal of the payment in period "x"
Usage
ppmt(pv, fv = 0, n, r, x, end = TRUE)
Arguments
| pv | Present Value | 
| fv | Future Value | 
| n | Number of Periods | 
| r | Rate | 
| x | Period in which to calculate the principal portion of the payment | 
| end | If FALSE, payments are made at the beginning of the period | 
Value
Returns the Principal Portion of the Payment in Period "x"
Examples
ppmt(pv  = 5000, fv = 0, n = 4 * 12, r = 0.06/12, x = 12, end = TRUE)
Present Value
Description
Calculates the present value of a given future value
Usage
pv(fv, r, n)
Arguments
| fv | Future Value | 
| r | Discount Rate | 
| n | Number of Compounding Periods | 
Value
Returns the Present Value
Examples
pv(5000, 0.08/12, 5*12)
Return Calculation
Description
Return Calculation
Usage
r.calc(vector)
Arguments
| vector | Vector from which to calculate the periodic return | 
Value
Returns the Periodic Percent Return
Examples
r.calc(c(100, 75, 50, 80, 125))
Amortization Schedule
Description
Creates an amortization schedule of a loan
Usage
schedule(r, n, pv, fv = 0, end = TRUE)
Arguments
| r | Rate | 
| n | Number of Periods | 
| pv | Present Value | 
| fv | Future Value, set = 0 | 
| end | If FALSE, payments are made at the beginning of the period | 
Value
Returns the Amortization Schedule in a dataframe
Examples
schedule(r = 0.06/12, n = 10 * 12, pv = -5000, fv = 0, end = TRUE)