Talk:Documentation/Calc Functions/XIRR

    From The Document Foundation Wiki

    SF Comments

    (1) Summary. For consistency with IRR, replace with “Calculates the internal rate of return for an irregular series of cash flows, iterating to find the rate of return which gives a zero net present value for the cash flows.”.
    (2) Returns. Insert “decimal” before “fraction”. Suggest change “a non-periodic” to “an irregular”. Need to clarify that the rate of return is per annum and that interest is compounded annually.
    (3) Arguments, Values. 1st sentence okay but suggest replacing the following sentences with “At least one of the cash flows must be negative and at least one must be positive to allow the net present value to be zero. The corresponding element of Dates specifies the date of a cash flow. The dimensions of Values and Dates should be the same and the order of the cash flow/date pairs is not important.”.
    (4) Arguments, Dates. Delete “those dates which are”. In second sentence, change “first” to “earliest”. Delete 3rd, 4th and 5th sentences, replacing them with “The corresponding element of Values specifies the value of a cash flow. The dimensions of Values and Dates should be the same and the order of the cash flow/date pairs is not important.”
    (5) Arguments, Guess. Please update to match the description of the same parameter for IRR.
    (6) Arguments, Warning. I see no need for this to be a warning on the wiki – I would prefer it to be a bullet – consistent with many other pages that highlight error conditions. Also correct the reference to the IRR function within the text of the warning. BUT - are you sure that this function raises an error 523? I cannot find evidence of this and wonder whether XIRR returns a 502 error to indicate non-convergence.
    (7) Arguments, bullet. Insert “the” before “dimensions”. Presumably, “Dates” and “Values” should be in bold.
    (8) Arguments, bullets. The code indicates that you will get an error if Guess is <= -1.0. It also indicates that you will get an error if there is only one cash flow / date pair.
    (9) Additional details. Include a link to Wikipedia’s page entitled “Internal rate of return”.
    (10) Additional details. Worth stating that “The rate of return is per annum and interest is assumed to be compounded annually, with a year assumed to be 365 days long”.
    (11) Additional details. Might also be worth adding that the result of XIRR is the rate at which the XNPV() function will return zero with the given cash flows (perhaps formatted as a formula).
    (12) Examples, 1st and 2nd examples. I am concerned that I get a different value (0.194818475056105) to that on the Help page and on this wiki page (0.182843485820784). I have used the DATE function to specify the dates in column A and wondered whether this somehow makes a difference?
    (13) Examples, 1st and 2nd examples. Suggest changing “mentioned” to “listed” (four occurrences).
    (14) Examples, 1st example. Formula indicates that a Guess of 0.1 is used; Description indicates that a Guess of 0.5 is used.

    --Stevefanning (talk) 2020-11-28T10:29:08 (UTC)