Skip to content

Clarify impact of datetime coordinate unit on polyfit, polyval, integrate, differentiate #9937

Open
@dcherian

Description

What is your issue?

We will soon support non-nanosecond time units. There are a few functions whose output could rely on the spacing of coordinate values: polyfit , polyval, integrate, differentiate (are there any more?)

  1. integrate and differentiate take a datetime_unit kwarg, polyfit and polyval do not.
  2. polyfit and polyval force conversion to ns:
    data=datetime_to_numeric(x.data, offset=offset, datetime_unit="ns"),

We probably want to relax (2) in the future. Either way it would be good to systematically think about this and at least talk about it in the docstrings.

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions