{"id":13699924,"url":"https://github.com/wegamekinglc/VisualPortfolio","last_synced_at":"2025-05-04T18:33:53.632Z","repository":{"id":62587586,"uuid":"45881906","full_name":"wegamekinglc/VisualPortfolio","owner":"wegamekinglc","description":null,"archived":false,"fork":false,"pushed_at":"2017-02-28T04:16:00.000Z","size":902,"stargazers_count":106,"open_issues_count":0,"forks_count":41,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-04-29T03:54:29.164Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wegamekinglc.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-11-10T02:26:27.000Z","updated_at":"2025-02-19T22:16:21.000Z","dependencies_parsed_at":"2022-11-03T22:42:02.986Z","dependency_job_id":null,"html_url":"https://github.com/wegamekinglc/VisualPortfolio","commit_stats":null,"previous_names":["chinaquants/visualportfolio"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wegamekinglc%2FVisualPortfolio","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wegamekinglc%2FVisualPortfolio/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wegamekinglc%2FVisualPortfolio/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wegamekinglc%2FVisualPortfolio/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wegamekinglc","download_url":"https://codeload.github.com/wegamekinglc/VisualPortfolio/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252382805,"owners_count":21739216,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-02T20:00:45.859Z","updated_at":"2025-05-04T18:33:52.440Z","avatar_url":"https://github.com/wegamekinglc.png","language":"Python","funding_links":[],"categories":["Python"],"sub_categories":["Risk Analysis","风险分析"],"readme":"------------------------------------------------------------\n|Join the chat at https://gitter.im/chinaquants/algotrading|\n------------------------------------------------------------\n\nVisualPortfolio\n=========================\n\n将策略或者资产包的表现可视化。大量参考以及模仿自 `pyfolio \u003chttps://github.com/quantopian/pyfolio\u003e`_ ，包括图的配置以及代码。\n\nThis tool is used to visualize the perfomance of a portfolio. Much of the codes and samples come from the original referenced project: `pyfolio \u003chttps://github.com/quantopian/pyfolio\u003e`_\n\n依赖\n----------------------\n\n::\n\n  lxml\n  matplotlib\n  numpy\n  pandas\n  seaborn\n  tushare\n\n\n安装\n----------------------\n\n首先将代码 ``clone`` 至本地：\n\n::\n\n  git clone https://github.com/ChinaQuants/VisualPortfolio.git (如果你是从github获取)\n\n\n安装\n\n::\n\n  cd VisualPortfolio\n  python setpy.py install\n\n例子\n----------------------\n\n.. code:: python\n\n  In [1]: %matplotlib inline\n  In [2]: from VisualPortfolio import createPerformanceTearSheet\n  In [3]: from pandas_datareader import data\n  In [4]: prices = data.get_data_yahoo('600000.ss')['Close']\n  In [5]: benchmark = data.get_data_yahoo('000300.ss')['Close']\n  ......: benchmark.name = \"000300.ss\"\n  In [6]: perf_matric, perf_df, rollingRisk = createPerformanceTearSheet(prices=prices, benchmark=benchmark)\n\n\n.. image:: img/1.png\n    :align: center\n\n.. image:: img/2.png\n    :align: center\n\n.. image:: img/3.png\n    :align: center\n\n.. image:: img/4.png\n    :align: center\n\n.. |Join the chat at https://gitter.im/chinaquants/algotrading| image:: https://badges.gitter.im/Join%20Chat.svg\n   :target: https://gitter.im/chinaquants/algotrading?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge\u0026utm_content=badge\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwegamekinglc%2FVisualPortfolio","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwegamekinglc%2FVisualPortfolio","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwegamekinglc%2FVisualPortfolio/lists"}