# irr

Internal rate of return

## Description

example

Return = irr(CashFlow) calculates the internal rate of return for a series of periodic cash flows.

irr uses the following conventions:

• If one or more internal rates of returns (warning if multiple) are strictly positive rates, Return sets to the minimum.

• If there is no strictly positive rate of returns, but one or multiple (warning if multiple) returns are nonpositive rates, Return sets to the maximum.

• If no real-valued rates exist, Return sets to NaN (no warnings).

example

[Return,AllRates] = irr(___) calculates the internal rate of return and a vector of all internal rates for a series of periodic cash flows.

## Examples

collapse all

Find the internal rate of return for a simple investment with a unique positive rate of return. The initial investment is \$100,000 and the following cash flows represent the yearly income from the investment

Year 1 \$10,000

Year 2 \$20,000

Year 3 \$30,000

Year 4 \$40,000

Year 5 \$50,000

Calculate the internal rate of return on the investment:

Return = irr([-100000 10000 20000 30000 40000 50000])
Return = 0.1201

If the cash flow payments were monthly, then the resulting rate of return is multiplied by 12 for the annual rate of return.

Find Multiple Internal Rates of Return

Find the internal rate of return for multiple rates of return. The project has the following cash flows and a market rate of 10%.

CashFlow = [-1000 6000 -10900 5800]
CashFlow = 1×4

-1000        6000      -10900        5800

[Return, AllRates] = irr(CashFlow)
Return = 1.0000
AllRates = 3×1

-0.0488
1.0000
2.0488

The rates of return in AllRates are -4.88%, 100%, and 204.88%. Though some rates are lower and some higher than the market rate, based on the work of Hazen, any rate gives a consistent recommendation on the project. However, you can use a present value analysis in these kinds of situations. To check the present value of the project, use pvvar:

PV = pvvar(CashFlow,0.10)
PV = -196.0932

The second argument is the 10% market rate. The present value is -196.0932, negative, so the project is undesirable.

## Input Arguments

collapse all

Stream of periodic cash flows, specified as a vector or matrix. The first entry in CashFlow is the initial investment. If CashFlow is a matrix, irr handles each column of CashFlow as a separate cash-flow stream.

Data Types: double

## Output Arguments

collapse all

Internal rate of return associated to CashFlow, returned as a vector whose entry j is an internal rate of return for column j in CashFlow

All the internal rates of return associated with CashFlow, returned as a matrix with the same number of columns as CashFlow and one less row. Also, column j in AllRates contains all the rates of return associated to column j in CashFlow (including complex-valued rates).

## References

[1] Brealey and Myers. Principles of Corporate Finance. McGraw-Hill Higher Education, Chapter 5, 2003.

[2] Hazen G. “A New Perspective on Multiple Internal Rates of Return.” The Engineering Economist. Vol. 48-1, 2003, pp. 31–51.

## Version History

Introduced before R2006a