incline.estimate_trend

incline.estimate_trend(df, value_column='value', time_column=None, method='smoothing_spline', derivative_order=1, with_uncertainty=False, **kwargs)[source]

Estimate a trend with a registered smoother.

Dispatches through the smoother registry rather than a hand-maintained branch per method, so a newly registered smoother is reachable here without editing this function.

Parameters:
  • df (pd.DataFrame) – Time series data.

  • value_column (str) – Column holding the values.

  • time_column (str | None) – Numeric time column.

  • method (str) – A registered smoother name.

  • derivative_order (int) – Which derivative to estimate.

  • with_uncertainty (bool) – Whether to compute standard errors.

  • **kwargs (Any) – Split between the smoother’s constructor and the uncertainty options of estimate().

Returns:

The input frame plus the estimate columns.

Raises:
  • ValueError – If method names no registered smoother.

  • TypeError – If a keyword matches neither the smoother’s constructor nor the uncertainty options.

Return type:

pd.DataFrame