{ "info": { "author": "Tibor Kiss", "author_email": "tibor.kiss@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 6 - Mature", "Operating System :: OS Independent", "Programming Language :: Python :: 3.7", "Topic :: Office/Business :: Financial :: Investment" ], "description": "Kelly Criterion\n===============\nMoney management strategy based on Kelly J. L.'s formula described in \"A New Interpretation of Information Rate\" [1]. \nThe formula was adopted to gambling and stock market by Ed Thorp, et al., see:\n\"The Kelly Criterion in Blackjack Sports Betting, and the Stock Market\" [2].\n\nThis program calculates the optimal capital allocation for the provided portfolio of securities with the formula:\n\n `f_i = m_i / s_i^2`\n\nwhere\n * `f_i` is the calculated leverage of the i-th security from the portfolio\n * `m_i` is the mean of the return of the i-th security from the portfolio\n * `s_i` is the standard deviation of the return of the i-th security from the portfolio\n\nassuming that the strategies for the securuties are all statistically independent.\n\nThe stock quotes are downloaded from Yahoo Finance using Pandas.\n\nReference (Matlab) implementation was taken from Ernie Chan's Quantitative Trading book [3].\n\nInstallation\n------------\n`pip install kelly_criterion`\n\nUsage\n-----\n`kelly_criterion [--risk-free-rate=] ...`\n\nExample\n-------\n```\n$ kelly_criterion --risk-free-rate 0.04 2001-02-26 2014-12-28 IBB VDE SPY\nKelly Criterion calculation\nArguments: risk-free-rate=0.04 start-date=2001-02-26 end-date=2014-12-28 securities=['IBB', 'VDE', 'SPY']\n\nLeverages per security:\n IBB: 3.61\n SPY: -2.73\n VDE: 1.04\nSum leverage: 1.92\n```\n\nDependencies\n------------\n * Python 2.7\n * [Numpy](http://www.numpy.org/)\n * [Pandas](http://pandas.pydata.org/)\n * [Docopt](http://docopt.org/)\n\nReferences\n----------\n * [1]: [A New Interpretation of Information Rate](http://ieeexplore.ieee.org/stamp/stamp.jsp?reload=true&tp=&arnumber=6771227)\n * [2]: [The Kelly Criterion in Blackjack Sports Betting, and the Stock Market](http://www.edwardothorp.com/sitebuildercontent/sitebuilderfiles/beatthemarket.pdf)\n * [3]: [Ernest P. Chan: Quantitative Trading (ISBN 978-0470284889)](http://www.amazon.com/Quantitative-Trading-Build-Algorithmic-Business/dp/0470284889)", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/kelly-direct/kelly-criterion", "keywords": "kelly-criterion kelly money-management", "license": "", "maintainer": "", "maintainer_email": "", "name": "kelly-criterion", "package_url": "https://pypi.org/project/kelly-criterion/", "platform": "", "project_url": "https://pypi.org/project/kelly-criterion/", "project_urls": { "Homepage": "https://github.com/kelly-direct/kelly-criterion" }, "release_url": "https://pypi.org/project/kelly-criterion/1.2.0/", "requires_dist": null, "requires_python": "", "summary": "Kelly Criterion Calculator", "version": "1.2.0" }, "last_serial": 4829712, "releases": { "1.0": [ { "comment_text": "", "digests": { "md5": "3f1cbf4c549c6b37d06a77f136252495", "sha256": "b2e970b3b7b3a20e84ce8391d04763f90c3281175b630b6e96dea9330e44d9a9" }, "downloads": -1, "filename": "kelly_criterion-1.0.tar.gz", "has_sig": false, "md5_digest": "3f1cbf4c549c6b37d06a77f136252495", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4292, "upload_time": "2016-06-29T06:20:36", "url": "https://files.pythonhosted.org/packages/91/71/84d68a183a4e90a9bb5c633aea68f027d02e7f8a870452159dea5777987f/kelly_criterion-1.0.tar.gz" } ], "1.2.0": [ { "comment_text": "", "digests": { "md5": "ec52549af563040b6135b6c41ac47460", "sha256": "d170e947d57881b911ced4e1b1ac657d68dc4f064924a71926c9c277541a73e7" }, "downloads": -1, "filename": "kelly_criterion-1.2.0.tar.gz", "has_sig": false, "md5_digest": "ec52549af563040b6135b6c41ac47460", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6684, "upload_time": "2019-02-16T20:18:36", "url": "https://files.pythonhosted.org/packages/6b/3c/1e15f96c1278cf99d164e430c80b0bef32f8a43c21ea4559b374ec40a272/kelly_criterion-1.2.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "ec52549af563040b6135b6c41ac47460", "sha256": "d170e947d57881b911ced4e1b1ac657d68dc4f064924a71926c9c277541a73e7" }, "downloads": -1, "filename": "kelly_criterion-1.2.0.tar.gz", "has_sig": false, "md5_digest": "ec52549af563040b6135b6c41ac47460", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6684, "upload_time": "2019-02-16T20:18:36", "url": "https://files.pythonhosted.org/packages/6b/3c/1e15f96c1278cf99d164e430c80b0bef32f8a43c21ea4559b374ec40a272/kelly_criterion-1.2.0.tar.gz" } ] }