Modified Jones-Faddy Skew t-Distributions for Financial Modeling
Project description
mjf-finance
Broken Symmetry of Stock Returns - Modified Jones-Faddy Skew t-Distributions
mjf-finance is a Python library that implements the Modified Jones-Faddy (mJF) Skew t-Distribution, a statistical model designed to capture the "broken symmetry" of stock market returns. Unlike traditional models that assume symmetry, mJF accounts for the fact that market crashes are more frequent and violent than rallies (negative skew) and that the market generally trends upwards over time.
Features
- mJF1 Distribution: Implements Eq. 20 from the paper, allowing for asymmetric power-law tails for gains and losses.
- Gain/Loss Decoupling: Analyze the "volatility of gains" and "volatility of losses" separately.
- Physics-Inspired: Parameters are derived from multiplicative stochastic volatility models, offering interpretability.
- Risk Metrics: Designed for better estimation of Value at Risk (VaR) and tail risk (Black Swans).
Installation
You can install the package using pip:
pip install mjf-finance
Or install from source:
git clone https://github.com/username/mjf-finance.git
cd mjf-finance
pip install .
Usage
Analyzing Returns
import numpy as np
from mjf_finance.distributions import pdf_mjf1
# Example parameters based on S&P 500 (illustrative)
mu = 0.0005 # Location parameter (drift)
alpha_g = 3.5 # Shape parameter for gains
alpha_l = 2.8 # Shape parameter for losses (heavier tail)
theta = 0.00015 # Mean variance
tau = 1.0 # Time increment (e.g., 1 day)
# Evaluate PDF at specific return
ret = -0.05 # 5% loss
density = pdf_mjf1(ret, mu, alpha_g, alpha_l, theta, tau)
print(f"Probability density at -5%: {density}")
Calculating Statistics
from mjf_finance.statistics import statistical_mean, statistical_variance
mean_val = statistical_mean(mu, alpha_g, alpha_l, theta, tau)
variance_val = statistical_variance(alpha_g, alpha_l, theta, tau)
print(f"Expected Return: {mean_val}")
print(f"Variance: {variance_val}")
References
This project incorporates research from the following paper:
- Broken Symmetry of Stock Returns -- a Modified Jones-Faddy Skew t-Distribution Siqi Shao, Arshia Ghasemi, Hamed Farahani, R. A. Serota arXiv:2512.23640
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 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 mjf_finance-0.1.0.tar.gz.
File metadata
- Download URL: mjf_finance-0.1.0.tar.gz
- Upload date:
- Size: 8.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5afee98c4f9228650b37177ad64eda30fac606389fb2f10f3b1def95ec4c57de
|
|
| MD5 |
f860a3bfa2b8f61b5ed7185d75ba2e7a
|
|
| BLAKE2b-256 |
f26f37ca01819263df7e5e54616401cfc14d88580ae0447e12ce645549d345de
|
Provenance
The following attestation bundles were made for mjf_finance-0.1.0.tar.gz:
Publisher:
publish.yml on kuslavicek/mjf-finance
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mjf_finance-0.1.0.tar.gz -
Subject digest:
5afee98c4f9228650b37177ad64eda30fac606389fb2f10f3b1def95ec4c57de - Sigstore transparency entry: 883921533
- Sigstore integration time:
-
Permalink:
kuslavicek/mjf-finance@9e63262e7c7e764465c27932a782df0607c192cc -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/kuslavicek
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@9e63262e7c7e764465c27932a782df0607c192cc -
Trigger Event:
release
-
Statement type:
File details
Details for the file mjf_finance-0.1.0-py3-none-any.whl.
File metadata
- Download URL: mjf_finance-0.1.0-py3-none-any.whl
- Upload date:
- Size: 7.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
65946cfd95d8cb256be353706553febf648aa3e6a56ddb91f5f8140e5ab5da73
|
|
| MD5 |
6b0422a94b4e50c35f2fdece7d400f6d
|
|
| BLAKE2b-256 |
7eb0cbfd69ba526f7dc8541b9ea3a9232749d73c9a984c69bcc980769cf7843f
|
Provenance
The following attestation bundles were made for mjf_finance-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on kuslavicek/mjf-finance
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mjf_finance-0.1.0-py3-none-any.whl -
Subject digest:
65946cfd95d8cb256be353706553febf648aa3e6a56ddb91f5f8140e5ab5da73 - Sigstore transparency entry: 883921583
- Sigstore integration time:
-
Permalink:
kuslavicek/mjf-finance@9e63262e7c7e764465c27932a782df0607c192cc -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/kuslavicek
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@9e63262e7c7e764465c27932a782df0607c192cc -
Trigger Event:
release
-
Statement type: