Rust-implemented time-series utilities exposed to Python via PyO3.
Reason this release was yanked:
mismatch in tags
Project description
rust_timeseries
rust_timeseries is a high-performance Python library for time-series diagnostics.
The first release implements the Escanciano–Lobato (2009) robust automatic portmanteau test for serial dependence.
Heavy lifting is handled in Rust (via PyO3) so you get C-level speed with a pure-Python interface.
✨ Highlights
| Why it matters | What you get |
|---|---|
| Native-code core | Tight Rust loops compiled to machine code |
| Zero-copy I/O | numpy.ndarray / pandas.Series buffers are viewed directly—no copying ever |
| Heteroskedastic-robust | τ̂-adjusted autocorrelations maintain validity under conditional heteroskedasticity |
| Automatic lag choice | Data-driven (p̃) maximises the penalised statistic (L_p) |
| Friendly errors | Clear ValueError / OSError when inputs are invalid |
📦 Installation
pip install rust_timeseries
Binary wheels are provided for Python 3.9–3.13 on Linux x86-64, macOS (Intel & Apple Silicon) and Windows 64-bit.
If no wheel matches your platform a source install will build automatically—just have Rust 1.76+ on PATH.
🚀 Quick start
import rust_timeseries as rts
import numpy as np
y = np.random.randn(500)
test = rts.statistical_tests.EscancianoLobato(y, q=3.5) # d defaults to ⌊n**0.2⌋
print(f"Q* = {test.statistic:.3f}")
print(f"p̃ = {test.p_tilde}")
print(f"p-value = {test.pvalue:.4f}")
API snapshot
| Object | Attribute | Meaning |
|---|---|---|
EscancianoLobato |
.statistic |
Robust Box–Pierce statistic (Q^{*}_{p̃}) |
.pvalue |
Asymptotic χ² (1) tail probability | |
.p_tilde |
Data-driven lag (p̃) |
Constructor signature
EscancianoLobato(data, /, *, q=2.4, d=None)
⚙️ How it works
All numerics live in safe Rust (src/), compiled into a shared library and imported by Python.
The Rust crate is internal; no stable Rust API is promised.
🛠 Development setup
git clone https://github.com/your-org/rust_timeseries
cd rust_timeseries
python -m venv .venv && source .venv/bin/activate
pip install -U pip maturin
maturin develop --features pyo3/extension-module
pytest
📜 License
Released under the MIT License – free for commercial and academic use.
📖 Reference
Escanciano, J. C. & Lobato, I. N. (2009). Testing serial correlation in time series with missing observations. Journal of Econometrics 150, 209–225.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file rust_timeseries-0.1.1.tar.gz.
File metadata
- Download URL: rust_timeseries-0.1.1.tar.gz
- Upload date:
- Size: 13.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
69d9414e6619cc91c7ccea0aa52a9c601e57859e162b9df97bb461410c46f98c
|
|
| MD5 |
931fae7c3237e366b008df7ad6365d9f
|
|
| BLAKE2b-256 |
87374d4fd4c5bd7f13161e4ba75a222ce2cf201e0350281f067d3c156b8c5bb8
|
File details
Details for the file rust_timeseries-0.1.1-cp313-cp313-win_amd64.whl.
File metadata
- Download URL: rust_timeseries-0.1.1-cp313-cp313-win_amd64.whl
- Upload date:
- Size: 147.8 kB
- Tags: CPython 3.13, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ff27f81bce7b7bc4ded20e34ce71677465d6270e9ad71e4a768cba1c788baa9d
|
|
| MD5 |
f80a1677dd7221402a761fedf7498423
|
|
| BLAKE2b-256 |
a9437fdf9d5345267cd12850a83533c64e8be8f04b472422c69a3e27b05475e4
|
File details
Details for the file rust_timeseries-0.1.1-cp313-cp313-manylinux_2_34_x86_64.whl.
File metadata
- Download URL: rust_timeseries-0.1.1-cp313-cp313-manylinux_2_34_x86_64.whl
- Upload date:
- Size: 290.4 kB
- Tags: CPython 3.13, manylinux: glibc 2.34+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6f2e81bead115d34948e9a6241175eda1397a57dcba66343aaa0fd560ddafafa
|
|
| MD5 |
8cd4eb577d8dc1c9a60ca9be86305994
|
|
| BLAKE2b-256 |
0555123a134d11b0eb024a7203de5ac622641313fa48bde897d53d60a630e1c3
|
File details
Details for the file rust_timeseries-0.1.1-cp313-cp313-macosx_11_0_arm64.whl.
File metadata
- Download URL: rust_timeseries-0.1.1-cp313-cp313-macosx_11_0_arm64.whl
- Upload date:
- Size: 254.4 kB
- Tags: CPython 3.13, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c83567dc6e016fc9e9405cdde46fbd3905c68abd9acae47e4f27218367b30a2e
|
|
| MD5 |
5158cf9db48c2e67ee5d6c531eed8031
|
|
| BLAKE2b-256 |
5e343ce015a26a7f622aa467014fec690e65d38c3c106aa0068f3e7c97ec9ed3
|
File details
Details for the file rust_timeseries-0.1.1-cp312-cp312-win_amd64.whl.
File metadata
- Download URL: rust_timeseries-0.1.1-cp312-cp312-win_amd64.whl
- Upload date:
- Size: 147.8 kB
- Tags: CPython 3.12, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
66907f8c5004f18bfa74ae02c2f9ed261fd77669a3ba39fa9bf3f2cfc9bda726
|
|
| MD5 |
017f799096d34d419378a8fe1d774936
|
|
| BLAKE2b-256 |
50ad1387e9c57f16f54707670adf54d40713980281bf703d28076e45a7dc9f18
|
File details
Details for the file rust_timeseries-0.1.1-cp312-cp312-manylinux_2_34_x86_64.whl.
File metadata
- Download URL: rust_timeseries-0.1.1-cp312-cp312-manylinux_2_34_x86_64.whl
- Upload date:
- Size: 290.3 kB
- Tags: CPython 3.12, manylinux: glibc 2.34+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b230840cff722387745928c587c41a082d68fe8ecbd0b7f6a23d33e99bd1a417
|
|
| MD5 |
5fd82ae020b1788e0d491ba10dc9a605
|
|
| BLAKE2b-256 |
643989d2d15eff8b0dc53b0f88af7ce31c0842f3dde079363a562b0c0273ac13
|
File details
Details for the file rust_timeseries-0.1.1-cp312-cp312-macosx_11_0_arm64.whl.
File metadata
- Download URL: rust_timeseries-0.1.1-cp312-cp312-macosx_11_0_arm64.whl
- Upload date:
- Size: 253.9 kB
- Tags: CPython 3.12, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
083e6a74d3f1e7dd4703bf1b7e82a16dbf20c677c5a8937b9240c2771040bb07
|
|
| MD5 |
c79ebf1e71087d02a18f4b71a10081e3
|
|
| BLAKE2b-256 |
55f48647db0bbaac6c01a316596826faf1a408c8721ec6749d7a55bd9ba11988
|
File details
Details for the file rust_timeseries-0.1.1-cp311-cp311-win_amd64.whl.
File metadata
- Download URL: rust_timeseries-0.1.1-cp311-cp311-win_amd64.whl
- Upload date:
- Size: 147.3 kB
- Tags: CPython 3.11, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
590e37a3107a3ca25fdde2e8060092dabc57d5c5d133553b71dbe7f858ee5e04
|
|
| MD5 |
e3c9a4e5908cb04764faae4c3cdbc87c
|
|
| BLAKE2b-256 |
5fc09ec9077a565e6a7e8950dd5a8768234c5aad47a93d486854e63c10fec8ee
|
File details
Details for the file rust_timeseries-0.1.1-cp311-cp311-manylinux_2_34_x86_64.whl.
File metadata
- Download URL: rust_timeseries-0.1.1-cp311-cp311-manylinux_2_34_x86_64.whl
- Upload date:
- Size: 290.1 kB
- Tags: CPython 3.11, manylinux: glibc 2.34+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2c139a913e9e02bc93add013f59ec57b9e308a2f77fce23c74baab964d6d5fa6
|
|
| MD5 |
b63f47e2d917c79c0c868a1995941317
|
|
| BLAKE2b-256 |
ece6e250f8edb26fbb9df0e68338c00cf41f7886ea835d7ecae5e8c348d080bb
|
File details
Details for the file rust_timeseries-0.1.1-cp311-cp311-macosx_11_0_arm64.whl.
File metadata
- Download URL: rust_timeseries-0.1.1-cp311-cp311-macosx_11_0_arm64.whl
- Upload date:
- Size: 257.6 kB
- Tags: CPython 3.11, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d9ef67280d29cbc7226673d0ca72503f050efd4ad1417c24a2197627597d582b
|
|
| MD5 |
50e333f081e90bf31d4a229646949602
|
|
| BLAKE2b-256 |
0e6f1f2a34b170d1954d5cb836d9a2c75b5b280fedc3e2de8bb63bb1407883ea
|