Skip to main content

Multivariate fractional Brownian motion

Project description

Python 3x PyPI - Version

Multivariate fractional Brownian motion (mfBm)

This package provides implementation for the multivariate fractional Brownian motion and simple fractional brownian motion with the method described in [1].

Installation

The mfbm package is available on PyPI and can be install via pip with the following command:

pip install mfbm

Example usage

import numpy as np
from mfbm import MFBM

p = 5
H = np.linspace(0.6, 0.9, 5)
n = 100
T = 100

rho = 0.7 * np.ones((p, p))
np.fill_diagonal(rho, 1)

eta = np.ones_like(rho)
sigma = np.ones(len(H))

mfbm = MFBM(H, rho, eta, sigma)
ts = mfbm.sample(n, T)

Explanation of the parameters:

  • H: np.ndarray is a one dimensional array of the Hurst parameters, where all Hursts are in the range (0, 1).
  • rho: np.ndarray is a two dimensional array of the cross correlations between the multiple fBms, default is the identity matrix.
  • sigma: np.ndarray is a one dimensional array of the standard deviations of the single fBms, default is all ones.
  • n: int is the number of increaments to generate for the multivariate fractional Gaussian noise.
  • T: float is the time horizon of the mfBm, default is n.

mfbm

[1] Andrew T. A. Wood & Grace Chan (1994): Simulation of Stationary Gaussian Processes in [0, 1]^d , Journal of Computational and Graphical Statistics, 3:4, 409-432

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

mfbm-0.1.4.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mfbm-0.1.4-py3-none-any.whl (4.9 kB view details)

Uploaded Python 3

File details

Details for the file mfbm-0.1.4.tar.gz.

File metadata

  • Download URL: mfbm-0.1.4.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for mfbm-0.1.4.tar.gz
Algorithm Hash digest
SHA256 a184897475bbdc87b4a429df74b734364b0f98b97b99a1019a4f2f4ed5e6343f
MD5 8571c8a87ce0faf6f27f0268eda37a7a
BLAKE2b-256 f96dc3407ea6a4770bf6c5e6ce2530eefb1bdeabdd66d68c17dd59d0f35adf59

See more details on using hashes here.

File details

Details for the file mfbm-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: mfbm-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 4.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for mfbm-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 9e5875d53fec1bcf6e971285b72e948342a718a3af4d761c1eebd6cdf8336b11
MD5 c1d56b0f23567ab98e17caf4b16062dd
BLAKE2b-256 c7df4701bb44af27c3b22a82abf46aecf25368913e2c80c0426e5c7d61512943

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page