Skip to main content

Factorium

Python License: MIT PyPI

Factorium is a Polars-first factor research & backtesting toolkit.

  • Data pipeline: BinanceDataLoader + AggBar → multi-symbol OHLCV panel in one line.
  • Factor engine: Factor with rich TS/CS/math ops and expression parsing.
  • Analysis: FactorAnalyzer + FactorAnalysisResult for IC, quantile returns, and plots.
  • Backtest: VectorizedBacktester (exposed as factorium.backtest.Backtester) with Polars-vectorized PnL.
  • Research workflow: ResearchSession + FactorReport to tie everything into a notebook-friendly API.

For a Chinese introduction, see README_zh.md.


Installation

# Recommended
uv add factorium

# Or with pip
pip install factorium

Development setup:

git clone https://github.com/novis10813/factorium.git
cd factorium
uv sync --dev

Quick example

from factorium import ResearchSession

session = ResearchSession.from_parquet("data/btc_1h.parquet")

close = session.factor("close")
momentum = (close.ts_delta(20) / close.ts_shift(20)).cs_rank()

print(session.quick_report(momentum, periods=1))

More complete guides live under docs/:

  • docs/getting-started/quickstart.md
  • docs/user-guide/bar.md
  • docs/user-guide/factor.md
  • docs/user-guide/analyzer.md
  • docs/user-guide/backtest.md

License

MIT – see LICENSE.

Metadata

Release files for factorium 0.4.0

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

Source distribution (sdist)

Source distribution for factorium 0.4.0
File Size Uploaded
factorium-0.4.0.tar.gz 517.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for factorium 0.4.0
File Interpreter ABI Platform
factorium-0.4.0-py3-none-any.whl Python 3 none any Details

Total release size: 611.7 kB

Release files / factorium-0.4.0.tar.gz

Download URL factorium-0.4.0.tar.gz
Size 517.8 kB
Tags Source
SHA-256 checksum
How to use checksums
1ef95cdcb0ba28a893f342684ee705051c31db8fc3ddc0c6f25410a1af25152e
BLAKE2b-256 checksum
How to use checksums
8dec89df23c66e52900e80eef31d97a5112f8a39c0cb551be7d8d4f308dd37e4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Feb 17, 2026.

Transparency log

Release files / factorium-0.4.0-py3-none-any.whl

Download URL factorium-0.4.0-py3-none-any.whl
Size 93.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5338fd2d7edf3915c40662534ea80397a6f4ef6af2638f68ee1b2b1ca886f83c
BLAKE2b-256 checksum
How to use checksums
7aa80302a9bf8200a6da902e36ef54767c826a8c1b4e57aa20079ac7aaa1d804
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Feb 17, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.4.0 This release

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.1

2 release files

0.2.0

2 release files

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