Skip to content

durbyn

Python wrapper for Durbyn.jl time series forecasting

Scikit-learn-style API for 21 forecasting models powered by Julia.


durbyn brings the power of the Julia Durbyn.jl time series forecasting package to Python. It provides a familiar, class-based API with .fit() / .forecast() methods, numpy arrays, and optional pandas integration — while delegating all computation to Julia for performance.

Durbyn — Kurdish for "binoculars" (Dur, far + Byn, to see), embodies foresight through science. Like Hari Seldon's psychohistory in Asimov's Foundation, we seek to glimpse the shape of tomorrow through the disciplined clarity of mathematics.


About TAFS

TAFS (Time Series Analysis and Forecasting Society) is a non-profit association ("Verein") in Vienna, Austria. It connects academics, experts, practitioners, and students focused on time-series, forecasting, and decision science. Contributions remain fully open source. Learn more at taf-society.org.


Features

Exponential Smoothing

SES, Holt, Holt-Winters, and ETS with automatic model selection. Full parameter control.

ARIMA

Manual and automatic ARIMA/SARIMA with external regressors support.

BATS / TBATS

Complex and multiple seasonal patterns, including non-integer periods.

Theta

Theta method and automatic Theta model selection (STM, OTM, DSTM, DOTM).

Naive Methods

Naive, Seasonal Naive, Random Walk (with drift), and Mean forecast baselines.

Intermittent Demand

Croston's method and SBA/SBJ variants for sparse demand data.

ARAR / ARARMA

Memory-shortening AR and ARMA models (Brockwell & Davis, Parzen).

Diffusion

Bass, Gompertz, GS-Gompertz, and Weibull innovation diffusion models.


Installation

pip install durbyn

Requirements

durbyn requires Julia to be installed on your system. The juliacall package will manage the Julia runtime automatically.

For development with a local copy of Durbyn.jl:

pip install -e ".[dev]"
export DURBYN_JL_PATH=/path/to/Durbyn.jl

Optional dependencies:

pip install durbyn[pandas]     # pandas DataFrame support
pip install durbyn[plot]       # matplotlib plotting
pip install durbyn[all]        # both

Quick Example

from durbyn import AutoARIMA

# Fit an automatic ARIMA model
model = AutoARIMA().fit(y, m=12)

# Generate forecasts with prediction intervals
fc = model.forecast(h=12, level=[80, 95])

# Access results
print(fc.mean)            # point forecasts
print(fc.to_dataframe())  # pandas DataFrame
fc.plot()                 # matplotlib plot

What's Next