Polars-native factor signal validation toolkit for quantitative finance
Project description
Tests one factor. Screens a thousand.
A polars-native factor validator. It answers the core question — Does this factor possess predictive edge?
Installation
pip install factrix
# or
uv add factrix
See the installation guide for version pinning and development setup.
Typical usage
Single factor — IC evaluation
import factrix as fl
from factrix.preprocess.returns import compute_forward_return
raw = fl.datasets.make_cs_panel(n_assets=100, n_dates=500, ic_target=0.08, seed=2024)
panel = compute_forward_return(raw, forward_periods=5)
cfg = fl.AnalysisConfig.individual_continuous(metric=fl.Metric.IC, forward_periods=5)
profile = fl.evaluate(panel, cfg)
print(profile.verdict(), '| primary_p =', round(profile.primary_p, 4))
print(profile.diagnose()) # WarningCode / InfoCode list
Multi-factor BHY screening
profiles = [fl.evaluate(p, cfg) for p in [panel_a, panel_b, panel_c, panel_d, panel_e]]
survivors = fl.multi_factor.bhy(profiles, threshold=0.05)
Single-asset (timeseries) fallback
cfg = fl.AnalysisConfig.individual_continuous(metric=fl.Metric.IC, forward_periods=5)
profile = fl.evaluate(single_asset_panel, cfg) # mode auto-switches to TIMESERIES
print(profile.stats.get(fl.StatCode.TS_BETA))
Documentation
- Get Started — install, quickstart, three-axis concepts
- Guides — PANEL vs TIMESERIES, BHY batch screening, choosing a metric
- Reference — applicability tables, formulas, statistical methods
- Development — architecture, contributing
License
Released under the Apache License 2.0.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
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 factrix-0.8.0.tar.gz.
File metadata
- Download URL: factrix-0.8.0.tar.gz
- Upload date:
- Size: 193.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3e8db835d57f243a2237bf26131f47f7cc28af423dbdf0e9a828adcdbb0f6534
|
|
| MD5 |
e325a7b34385882714e076d0b83925b9
|
|
| BLAKE2b-256 |
c375f4134985041ff5181227e51e2faa573f6eafbb1bc72a9fce3152cf07c252
|
Provenance
The following attestation bundles were made for factrix-0.8.0.tar.gz:
Publisher:
release.yml on awwesomeman/factrix
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
factrix-0.8.0.tar.gz -
Subject digest:
3e8db835d57f243a2237bf26131f47f7cc28af423dbdf0e9a828adcdbb0f6534 - Sigstore transparency entry: 1457597066
- Sigstore integration time:
-
Permalink:
awwesomeman/factrix@feee053c1de0df31d8271b704a742584d4be6342 -
Branch / Tag:
refs/tags/v0.8.0 - Owner: https://github.com/awwesomeman
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@feee053c1de0df31d8271b704a742584d4be6342 -
Trigger Event:
push
-
Statement type:
File details
Details for the file factrix-0.8.0-py3-none-any.whl.
File metadata
- Download URL: factrix-0.8.0-py3-none-any.whl
- Upload date:
- Size: 164.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0c1fccbf579b0e0c64df5bb380d1bd44e49a27ef74ed979a017b8c7de37392d4
|
|
| MD5 |
a249c573f654852c4f92d80b94926b2e
|
|
| BLAKE2b-256 |
25db9962f866a723518592e7950013600d5980d946fae8cbfce059f2240fb437
|
Provenance
The following attestation bundles were made for factrix-0.8.0-py3-none-any.whl:
Publisher:
release.yml on awwesomeman/factrix
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
factrix-0.8.0-py3-none-any.whl -
Subject digest:
0c1fccbf579b0e0c64df5bb380d1bd44e49a27ef74ed979a017b8c7de37392d4 - Sigstore transparency entry: 1457597119
- Sigstore integration time:
-
Permalink:
awwesomeman/factrix@feee053c1de0df31d8271b704a742584d4be6342 -
Branch / Tag:
refs/tags/v0.8.0 - Owner: https://github.com/awwesomeman
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@feee053c1de0df31d8271b704a742584d4be6342 -
Trigger Event:
push
-
Statement type: