Skip to main content

QuantWave (Python)

Polars-native quantitative finance — 225 Rust indicators, Ehlers DSP, price action, regimes, and a built-in backtest engine with batch ↔ streaming parity.

pip install "quantwave[polars]"
quantwave doctor

Documentation · vs TA-Lib & pandas-ta · FAQ · llms.txt


Install

pip install "quantwave[polars]"

The wheel bundles quantwave._quantwave (indicators), quantwave_plugins (expression .ta), and quantwave._backtest. The [polars] extra adds Polars for .ta / .bt namespaces.


Example 1 — Polars batch (.ta)

import polars as pl
import quantwave  # registers pl.col().ta and LazyFrame.bt

df = pl.DataFrame({
    "high":  [101.0, 102.0, 103.0, 102.0, 104.0],
    "low":   [99.0, 100.0, 101.0, 100.0, 102.0],
    "close": [100.0, 101.0, 102.0, 101.0, 103.0],
})

out = (
    df.lazy()
    .with_columns(
        pl.col("close").ta.rsi(timeperiod=14).alias("rsi"),
        pl.col("close").ta.supertrend("high", "low", period=10, multiplier=3.0).alias("st"),
    )
    .collect()
)
print(out.tail())

Example 2 — Live streaming (parity with batch)

import quantwave as qw

cls = qw.streaming_class("rsi")
rsi = qw.wrap_streaming(cls(period=14), name="rsi")

for price in closes:
    val = rsi.next(price)
    if rsi.is_ready:
        print(price, val)

# Optional: qw.assert_parity("rsi", {"period": 14}, closes)

Example 3 — Backtest (.bt in the same package)

import polars as pl
import quantwave

bars = pl.DataFrame({
    "timestamp": range(20),
    "close": [100 + i * 0.5 for i in range(20)],
    "signal": [0.0, 0.0, 1.0, 1.0, 1.0, 0.0, 0.0, -1.0, -1.0, 0.0] * 2,
})

report = (
    bars.lazy()
    .bt.backtest_with_report(signal="signal", close_col="close", timestamp_col="timestamp")
)
print(report.metrics())

See examples/03_backtest_quick.py in this directory.


Architecture

pip install quantwave[polars]
        │
        ├── quantwave._quantwave   # Rust indicators (Next<T> core)
        ├── quantwave_plugins    # pl.col("close").ta.* expression plugins
        ├── quantwave._backtest  # Rust simulation engine
        │
        ├── import quantwave
        │     ├── pl.col().ta.*        batch indicators (plugins)
        │     ├── df.lazy().bt.*       backtest namespace (bt_polars)
        │     ├── qw.streaming_class   live bar-by-bar
        │     ├── qw.metadata / assert_parity / CLI
        │     └── quantwave.backtest   BacktestEngine direct API
        │
        └── Docs: lavs9.github.io/quantwave/api/ (mkdocstrings)

One Rust math path powers batch, streaming, and backtest signal evaluation — validated by gold-standard tests.


Discovery & CLI

import quantwave as qw

print(len(qw.indicators()), "names")
meta = qw.metadata("rsi")
print(meta.warmup_bars, meta.category)
quantwave list --category "Classic"
quantwave info supertrend
quantwave doctor

Examples in this repo

Script What it shows
examples/01_rsi_polars.py Polars .ta batch
examples/02_supertrend_streaming.py RSI streaming + readiness
examples/03_backtest_quick.py .bt.backtest_with_report

Learn more

MIT licensed.

Metadata

Release files for quantwave 0.9.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for quantwave 0.9.0
File Actions
quantwave-0.9.0-cp39-abi3-win_amd64.whl CPython 3.9 abi3 Windows x86-64 Details for quantwave-0.9.0-cp39-abi3-win_amd64.whl
quantwave-0.9.0-cp39-abi3-manylinux_2_35_x86_64.whl CPython 3.9 abi3 Linux glibc 2.35+ x86-64 Details for quantwave-0.9.0-cp39-abi3-manylinux_2_35_x86_64.whl
quantwave-0.9.0-cp39-abi3-manylinux_2_35_aarch64.whl CPython 3.9 abi3 Linux glibc 2.35+ ARM64 Details for quantwave-0.9.0-cp39-abi3-manylinux_2_35_aarch64.whl
quantwave-0.9.0-cp39-abi3-macosx_11_0_arm64.whl CPython 3.9 abi3 macOS 11.0+ ARM64 Details for quantwave-0.9.0-cp39-abi3-macosx_11_0_arm64.whl

Total release size: 53.8 MB

Release files / quantwave-0.9.0-cp39-abi3-win_amd64.whl

Download URL quantwave-0.9.0-cp39-abi3-win_amd64.whl
Size 12.9 MB
Tags CPython 3.9 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
43ef0b74ae789ab228e337b743d42932eab59dfde596c3be711a40cc5530ddd9
BLAKE2b-256 checksum
How to use checksums
30f10f5dbcd438d5f7a443f89fec1998fccbb819b2fa1dc8095b840ee3dd8e2c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

Release files / quantwave-0.9.0-cp39-abi3-manylinux_2_35_x86_64.whl

Download URL quantwave-0.9.0-cp39-abi3-manylinux_2_35_x86_64.whl
Size 13.6 MB
Tags CPython 3.9 Linux glibc 2.35+ x86-64 abi3
SHA-256 checksum
How to use checksums
7238d0e6e0bc230a7eedca529b44319a57fa741472055206e964edcb4ec06126
BLAKE2b-256 checksum
How to use checksums
1a8556e52efe550a39c9d957f4783119278ab86ee717933cd9a698131ee3a529
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

Release files / quantwave-0.9.0-cp39-abi3-manylinux_2_35_aarch64.whl

Download URL quantwave-0.9.0-cp39-abi3-manylinux_2_35_aarch64.whl
Size 14.9 MB
Tags CPython 3.9 Linux glibc 2.35+ ARM64 abi3
SHA-256 checksum
How to use checksums
e1e9cae652e2ff6293d27638fccb6627a333279bd67f0d5d87ea1948f9b6f034
BLAKE2b-256 checksum
How to use checksums
3dd2bf80d43aba4a53fc48c9f7c35d435d90fa4c1d1662e3f5cc294dbab77e75
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

Release files / quantwave-0.9.0-cp39-abi3-macosx_11_0_arm64.whl

Download URL quantwave-0.9.0-cp39-abi3-macosx_11_0_arm64.whl
Size 12.4 MB
Tags CPython 3.9 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
b0ba0272f3115b8ad79876773b00898151c074bc8cb9e1fd028fabb2c86e0106
BLAKE2b-256 checksum
How to use checksums
8ab1f1f718c5d4a400fe6c14c6f029be79cbe1ce6b5a137d79c6cb2e2b08d3e0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

Security for quantwave 0.9.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 4 files in this release have been uploaded with provenance metadata.

Select from 4 files

Attestation for quantwave-0.9.0-cp39-abi3-win_amd64.whl

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 10, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page