Xpectral Quant
Quant analytics and market data that extend Polars DataFrames via the accessor pattern.
Part of the Xpectral project, alongside xpectral-chart
(fluent Bokeh charting). Each installs its own top-level package
(xpectral_quant and xpectral_chart) and they can be used together.
Modules
xpectral_quant.quant: Financial metrics (returns, volatility, beta) viapl.col(...).quant.returns(), plus aPortfoliobuilder.xpectral_quant.data: Market data from the Polygon/Massive API with caching and rate limiting, plus simulations (BrownianMotion).
Usage
import xpectral_quant.quant # registers the .quant accessor
import polars as pl
df = pl.DataFrame({"close": [100.0, 101.0, 99.5, 102.0]})
df.with_columns(pl.col("close").quant.returns())
Importing xpectral_quant.quant / xpectral_quant.data is what registers the accessors and
loads market-data credentials.
Market data credentials
xpectral_quant.data reads Polygon/Massive API credentials from an xpectral_quant/.env
file (loaded automatically on import xpectral_quant.data). Create it with your keys;
it is git-ignored and never committed.
Install
pip install xpectral-quant
uv add xpectral-quant
For development:
uv sync
Metadata
Release files for xpectral-quant 2.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| xpectral_quant-2.0.0.tar.gz | 2.1 MB | With provenance | Details for xpectral_quant-2.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| xpectral_quant-2.0.0-py3-none-any.whl | Python 3 | none | any | Details for xpectral_quant-2.0.0-py3-none-any.whl |
Total release size: 2.1 MB
Release files / xpectral_quant-2.0.0.tar.gz
| Download URL | xpectral_quant-2.0.0.tar.gz |
|---|---|
| Size | 2.1 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c63bdc87b1164ae446d56e1e2059bb8ad7aa711d2099162120c56d56eece40f4
|
|
BLAKE2b-256 checksum How to use checksums |
18bf28685a3d94400fbde3943cfdb9fa783287daa3bc380abbb9cf3789a0f1e9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Oct 14, 2026.
Transparency logRelease files / xpectral_quant-2.0.0-py3-none-any.whl
| Download URL | xpectral_quant-2.0.0-py3-none-any.whl |
|---|---|
| Size | 31.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6d0d02425325fa85b9bfe90decd33f25e4553daca4905d187355617ea12c39a9
|
|
BLAKE2b-256 checksum How to use checksums |
dd8bde1741aaec5b1cd80f157b9ec914483909cbec512f275a1be48d729ad6a9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Oct 14, 2026.
Transparency logSecurity for xpectral-quant 2.0.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
Both files in this release have been uploaded with provenance metadata.
Attestation for xpectral_quant-2.0.0.tar.gz
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 Oct 14, 2026.
Transparency logA 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.