Skip to content

AstrocyteResearch/portformer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

https://circleci.com/gh/AstrocyteResearch/portformer/tree/master.svg?style=shield https://codecov.io/gh/AstrocyteResearch/portformer/branch/master/graph/badge.svg?token=6NVZUGMEZ8 https://img.shields.io/badge/STAR_Me_on_GitHub!--None.svg?style=social

Portformer: Portfolios. Made Better.

Welcome to the documentation for the wrapper for of Portformer's API https://analysis.portformer.com/docs

This is a product of Portformer by Astrocyte Research

Install

portformer is released on PyPI, so all you need is:

$ pip install portformer

To upgrade to latest version:

$ pip install --upgrade portformer

Usage

from portformer import BreakpointAPI
api = BreakpointAPI(api_key="ENTER_YOUR_KEY")

# Get the latest breakpoint risks and forecasts for TSLA
breakpoint_forecast = api.forecast("TSLA")

Development

$ # create venv
$ virtualenv -p python3.8 venv

$ # Install
$ pip install -r requirements.txt
$ pip install -r requirements-dev.txt
$ pip install -e .

Test

$ python ./tests/all.py

Build

$ python3 -m pip install --user --upgrade setuptools wheel
$ python3 setup.py sdist bdist_wheel

Deploy

$ # Update coverage
$ coverage xml
$ bash <(curl -s https://codecov.io/bash)
$ # Build
$ rm ./dist/portformer-* || python3 setup.py sdist bdist_wheel
$ # Upload to pypi
$ python3 -m twine upload dist/*