Skip to content

Divergence at IRR values near zero #1

@aziadeh

Description

@aziadeh

Hey,

Really like how fast the algorithm is but at IRR values that are supposed to be close to zero, the irr_binary_search calculation diverges, irr_newton seem to find the proper solution as well as numpy.irr.

Here's an example of a list that would return a -1 instead of -.01:
[-13897.515699392789, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, 678.69417667002108, -426.40303828879155]
You've ever ran into such problems?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions