IRR {FinancialMath}R Documentation

Internal Rate of Return

Description

Calculates internal rate of return for a series of cash flows, and provides a time diagram of the cash flows.

Usage

IRR(cf0,cf,times,plot=FALSE)

Arguments

cf0

cash flow at period 0

cf

vector of cash flows

times

vector of the times for each cash flow

plot

option whether or not to provide the time diagram

Details

cf0=\sum_{k=1}^n\frac{cf_k}{(1+irr)^{times_k}}

Value

The internal rate of return.

Note

Periods in t must be positive integers.

Uses polyroot function to solve equation given by series of cash flows, meaning that in the case of having a negative IRR, multiple answers may be returned.

Author(s)

Kameron Penn and Jack Schmidt

See Also

NPV

Examples

IRR(cf0=1,cf=c(1,2,1),times=c(1,3,4))

IRR(cf0=100,cf=c(1,1,30,40,50,1),times=c(1,1,3,4,5,6))

[Package FinancialMath version 0.1.1 Index]