![](http://pmorissette.github.io/ffn/_static/logo.png)
[![Build Status](https://github.com/pmorissette/ffn/workflows/Build%20Status/badge.svg)](https://github.com/pmorissette/ffn/actions/)
[![Codecov](https://codecov.io/gh/pmorissette/ffn/branch/master/graph/badge.svg)](https://codecov.io/pmorissette/ffn)
[![PyPI Version](https://img.shields.io/pypi/v/ffn)](https://pypi.org/project/ffn/)
[![PyPI License](https://img.shields.io/pypi/l/ffn)](https://pypi.org/project/ffn/)
# ffn - Financial Functions for Python
Alpha release - please let me know if you find any bugs!
If you are looking for a full backtesting framework, please check out [bt](https://github.com/pmorissette/bt).
bt is built atop ffn and makes it easy and fast to backtest quantitative strategies.
## Overview
ffn is a library that contains many useful functions for those who work in **quantitative
finance**. It stands on the shoulders of giants (Pandas, Numpy, Scipy, etc.) and provides
a vast array of utilities, from performance measurement and evaluation to
graphing and common data transformations.
```python
import ffn
returns = ffn.get('aapl,msft,c,gs,ge', start='2010-01-01').to_returns().dropna()
returns.calc_mean_var_weights().as_format('.2%')
aapl 62.54%
c -0.00%
ge 36.19%
gs -0.00%
msft 1.26%
dtype: object
```
## Installation
The easiest way to install `ffn` is from the [Python Package Index](https://pypi.python.org/pypi/ffn/)
using `pip`.
```bash
pip install ffn
```
Since ffn has many dependencies, we strongly recommend installing the [Anaconda Scientific Python Distribution](https://store.continuum.io/cshop/anaconda/). This distribution comes with many of the required packages pre-installed, including pip. Once Anaconda is installed, the above command should complete the installation.
## Documentation
Read the docs at http://pmorissette.github.io/ffn
- [Quickstart](http://pmorissette.github.io/ffn/quick.html)
- [Full API](http://pmorissette.github.io/ffn/ffn.html)
Raw data
{
"_id": null,
"home_page": "",
"name": "ffn",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": "",
"keywords": "python,finance,quant,quant finance,algotrading,algorithmic trading",
"author": "",
"author_email": "Philippe Morissette <morissette.philippe@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/70/49/92d9d6c2236a80a5c55e39085b4df00e72d97464c9ce8da4bfa5ee0f07b2/ffn-1.0.1.tar.gz",
"platform": null,
"description": "![](http://pmorissette.github.io/ffn/_static/logo.png)\n\n[![Build Status](https://github.com/pmorissette/ffn/workflows/Build%20Status/badge.svg)](https://github.com/pmorissette/ffn/actions/)\n[![Codecov](https://codecov.io/gh/pmorissette/ffn/branch/master/graph/badge.svg)](https://codecov.io/pmorissette/ffn)\n[![PyPI Version](https://img.shields.io/pypi/v/ffn)](https://pypi.org/project/ffn/)\n[![PyPI License](https://img.shields.io/pypi/l/ffn)](https://pypi.org/project/ffn/)\n\n# ffn - Financial Functions for Python\n\nAlpha release - please let me know if you find any bugs!\n\nIf you are looking for a full backtesting framework, please check out [bt](https://github.com/pmorissette/bt).\nbt is built atop ffn and makes it easy and fast to backtest quantitative strategies.\n\n## Overview\n\nffn is a library that contains many useful functions for those who work in **quantitative\nfinance**. It stands on the shoulders of giants (Pandas, Numpy, Scipy, etc.) and provides\na vast array of utilities, from performance measurement and evaluation to\ngraphing and common data transformations.\n\n```python\nimport ffn\nreturns = ffn.get('aapl,msft,c,gs,ge', start='2010-01-01').to_returns().dropna()\nreturns.calc_mean_var_weights().as_format('.2%')\n aapl 62.54%\n c -0.00%\n ge 36.19%\n gs -0.00%\n msft 1.26%\n dtype: object\n```\n\n\n## Installation\n\nThe easiest way to install `ffn` is from the [Python Package Index](https://pypi.python.org/pypi/ffn/)\nusing `pip`.\n\n```bash\npip install ffn\n```\n\nSince ffn has many dependencies, we strongly recommend installing the [Anaconda Scientific Python Distribution](https://store.continuum.io/cshop/anaconda/). This distribution comes with many of the required packages pre-installed, including pip. Once Anaconda is installed, the above command should complete the installation.\n\n## Documentation\n\nRead the docs at http://pmorissette.github.io/ffn\n\n- [Quickstart](http://pmorissette.github.io/ffn/quick.html)\n- [Full API](http://pmorissette.github.io/ffn/ffn.html)\n",
"bugtrack_url": null,
"license": "",
"summary": "Financial functions for Python",
"version": "1.0.1",
"project_urls": {
"Homepage": "http://pmorissette.github.io/ffn/",
"Repository": "https://github.com/pmorissette/ffn"
},
"split_keywords": [
"python",
"finance",
"quant",
"quant finance",
"algotrading",
"algorithmic trading"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "704992d9d6c2236a80a5c55e39085b4df00e72d97464c9ce8da4bfa5ee0f07b2",
"md5": "c7ff59147f84e507b25a5c0b8cf4c697",
"sha256": "e2609e32cb9030a9afc77aaa96ab37757d21864f2e1be2842438a6ac12030714"
},
"downloads": -1,
"filename": "ffn-1.0.1.tar.gz",
"has_sig": false,
"md5_digest": "c7ff59147f84e507b25a5c0b8cf4c697",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 26886,
"upload_time": "2023-12-31T15:47:45",
"upload_time_iso_8601": "2023-12-31T15:47:45.947188Z",
"url": "https://files.pythonhosted.org/packages/70/49/92d9d6c2236a80a5c55e39085b4df00e72d97464c9ce8da4bfa5ee0f07b2/ffn-1.0.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-12-31 15:47:45",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "pmorissette",
"github_project": "ffn",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "ffn"
}