Skip to main content

Survivial probability estimator for Regime Switching Orstein-Uhlenbeck triply stochastic process

Project description

homogenize

Analytical formulas for survival in regime switching Orstein-Uhlenbeck processes

Hi there

This package exists for one purpose only: estimation of survival probability for a triply stochastic regime switching process using a fairly advanced technique, asymptotic homogenization. I'm still tinkering with it and there might yet be bugs ... so caveat emptor. The calculation is from the back of my phd thesis 18 years ago so I'm a bit rusty :) The technique is not like a series expansion that is more accurate near t=0, rather it is more accurate for larger t. A little counterintuitive. It needs to be used with care and I recommend running the simulations to get a sense.

If you are truly interested there is a draft shared on Overleaf: https://www.overleaf.com/read/rqkgmnqfsvvm If you discover a bug in the maple code for generating the series expansion or the python code it is translated to I will be forever greatful.

-Peter

Usage

To use the survival probability estimator

from homogenize import RegimeSwitchingModel
params = {'kappa': 2.0, 'thetas': [0.15, 0.02], 'sigmas': [math.sqrt(0.0555), math.sqrt(0.0055)], 'lmbd': 1.7}
model = RegimeSwitchingModel(**params)
model.u(x=0.12,t=7.2) 

To check against simulation

from homogenize import demo
demo() 

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

homogenize-0.0.1.tar.gz (7.8 kB view details)

Uploaded Source

Built Distribution

homogenize-0.0.1-py3-none-any.whl (8.2 kB view details)

Uploaded Python 3

File details

Details for the file homogenize-0.0.1.tar.gz.

File metadata

  • Download URL: homogenize-0.0.1.tar.gz
  • Upload date:
  • Size: 7.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.6

File hashes

Hashes for homogenize-0.0.1.tar.gz
Algorithm Hash digest
SHA256 d53ecbfb0223083cea8c0cff4cefc782ea9fbcda260f2d77247f07dba8a0099f
MD5 32d1b8bdc8a67b215eecf4596e558f18
BLAKE2b-256 c67aa4daeeb64fb6ea7372fdfd1c731384f7e2d9e6390bc7b975887a8c29bfbb

See more details on using hashes here.

File details

Details for the file homogenize-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: homogenize-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 8.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.6

File hashes

Hashes for homogenize-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 2790557ac67d336791ea0e14426a3158f1dbb0c3b7ba87ddcc5295b7cf837478
MD5 383be503d9c17944a6d8069898366802
BLAKE2b-256 8c57ce2d33adec17e1513ee8eb52abd6dcf0646a6d1a0df3e6d96c4d1536674e

See more details on using hashes here.

Supported by

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