finance v0.0.4 Finance

Library to calculate IRR through the Bisection method.

Link to this section Summary

Functions

iex> d = [{2015, 11, 1}, {2015,10,1}, {2015,6,1}] iex> v = [-800_000, -2_200_000, 1_000_000] iex> Finance.xirr(d,v) { :ok, 21.118359 }

Link to this section Types

Link to this type date()
date() :: Date.t
Link to this type rate()
rate() :: float

Link to this section Functions

Link to this function xirr(dates, values)
xirr([date], [number]) :: rate

iex> d = [{2015, 11, 1}, {2015,10,1}, {2015,6,1}] iex> v = [-800_000, -2_200_000, 1_000_000] iex> Finance.xirr(d,v) { :ok, 21.118359 }