IRR(values[,guess])
IRR calculates and returns the internal rate of return of an investment. This function is closely related to the net present value function (NPV). The IRR is the interest rate for a series of cash flows where the net preset value is zero.
values contains the series of cash flows generated by the investment. The payments should occur at regular intervals. The optional guess is the initial value used in calculating the IRR. You do not have to use that, it is only provided for the Excel compatibility.
Let us assume that the cells A1:A8 contain the numbers -32432, 5324, 7432, 9332, 12324, 4334, 1235, -3422. Then
IRR(A1:A8) returns 0.04375.