pfund-plot 0.0.1__tar.gz → 0.0.1.dev2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. pfund_plot-0.0.1.dev2/LICENSE +201 -0
  2. pfund_plot-0.0.1.dev2/PKG-INFO +43 -0
  3. pfund_plot-0.0.1.dev2/README.md +3 -0
  4. pfund_plot-0.0.1.dev2/pfund_plot/__init__.py +1 -0
  5. pfund_plot-0.0.1.dev2/pyproject.toml +46 -0
  6. pfund_plot-0.0.1/PKG-INFO +0 -148
  7. pfund_plot-0.0.1/README.md +0 -99
  8. pfund_plot-0.0.1/pfund_plot/__init__.py +0 -183
  9. pfund_plot-0.0.1/pfund_plot/__main__.py +0 -9
  10. pfund_plot-0.0.1/pfund_plot/cli/__init__.py +0 -3
  11. pfund_plot-0.0.1/pfund_plot/cli/commands/gallery/__init__.py +0 -15
  12. pfund_plot-0.0.1/pfund_plot/cli/commands/gallery/gallery_marimo.py +0 -462
  13. pfund_plot-0.0.1/pfund_plot/cli/commands/serve.py +0 -21
  14. pfund_plot-0.0.1/pfund_plot/cli/main.py +0 -20
  15. pfund_plot-0.0.1/pfund_plot/config.py +0 -109
  16. pfund_plot-0.0.1/pfund_plot/enums/__init__.py +0 -16
  17. pfund_plot-0.0.1/pfund_plot/enums/dataframe_backend.py +0 -6
  18. pfund_plot-0.0.1/pfund_plot/enums/display_mode.py +0 -7
  19. pfund_plot-0.0.1/pfund_plot/enums/panel_design.py +0 -8
  20. pfund_plot-0.0.1/pfund_plot/enums/panel_theme.py +0 -6
  21. pfund_plot-0.0.1/pfund_plot/enums/plotting_backend.py +0 -12
  22. pfund_plot-0.0.1/pfund_plot/js_tap/components/candlestick.js +0 -9566
  23. pfund_plot-0.0.1/pfund_plot/mixins/streaming_market_feed_mixin.py +0 -162
  24. pfund_plot-0.0.1/pfund_plot/plots/altair.py +0 -32
  25. pfund_plot-0.0.1/pfund_plot/plots/area/__init__.py +0 -82
  26. pfund_plot-0.0.1/pfund_plot/plots/area/bokeh.py +0 -151
  27. pfund_plot-0.0.1/pfund_plot/plots/bar/__init__.py +0 -80
  28. pfund_plot-0.0.1/pfund_plot/plots/bar/bokeh.py +0 -128
  29. pfund_plot-0.0.1/pfund_plot/plots/bokeh.py +0 -32
  30. pfund_plot-0.0.1/pfund_plot/plots/candlestick/__init__.py +0 -77
  31. pfund_plot-0.0.1/pfund_plot/plots/candlestick/bokeh.py +0 -124
  32. pfund_plot-0.0.1/pfund_plot/plots/candlestick/svelte.py +0 -161
  33. pfund_plot-0.0.1/pfund_plot/plots/holoviews.py +0 -32
  34. pfund_plot-0.0.1/pfund_plot/plots/label/__init__.py +0 -43
  35. pfund_plot-0.0.1/pfund_plot/plots/label/bokeh.py +0 -89
  36. pfund_plot-0.0.1/pfund_plot/plots/layout/__init__.py +0 -98
  37. pfund_plot-0.0.1/pfund_plot/plots/layout/layout.py +0 -116
  38. pfund_plot-0.0.1/pfund_plot/plots/layout/panel.py +0 -51
  39. pfund_plot-0.0.1/pfund_plot/plots/layout/tabs/__init__.py +0 -36
  40. pfund_plot-0.0.1/pfund_plot/plots/layout/tabs/panel.py +0 -51
  41. pfund_plot-0.0.1/pfund_plot/plots/lazy.py +0 -408
  42. pfund_plot-0.0.1/pfund_plot/plots/line/__init__.py +0 -37
  43. pfund_plot-0.0.1/pfund_plot/plots/line/bokeh.py +0 -137
  44. pfund_plot-0.0.1/pfund_plot/plots/matplotlib.py +0 -32
  45. pfund_plot-0.0.1/pfund_plot/plots/plot.py +0 -1131
  46. pfund_plot-0.0.1/pfund_plot/plots/plotly.py +0 -32
  47. pfund_plot-0.0.1/pfund_plot/plots/scatter/__init__.py +0 -62
  48. pfund_plot-0.0.1/pfund_plot/plots/scatter/bokeh.py +0 -158
  49. pfund_plot-0.0.1/pfund_plot/plots/scatter/marker.py +0 -107
  50. pfund_plot-0.0.1/pfund_plot/plots/ta.py +0 -6
  51. pfund_plot-0.0.1/pfund_plot/renderers/base.py +0 -84
  52. pfund_plot-0.0.1/pfund_plot/renderers/browser.py +0 -28
  53. pfund_plot-0.0.1/pfund_plot/renderers/desktop.py +0 -109
  54. pfund_plot-0.0.1/pfund_plot/renderers/notebook.py +0 -92
  55. pfund_plot-0.0.1/pfund_plot/typing.py +0 -29
  56. pfund_plot-0.0.1/pfund_plot/utils/__init__.py +0 -176
  57. pfund_plot-0.0.1/pfund_plot/utils/bokeh.py +0 -177
  58. pfund_plot-0.0.1/pfund_plot/widgets/base.py +0 -76
  59. pfund_plot-0.0.1/pfund_plot/widgets/datetime_widget.py +0 -221
  60. pfund_plot-0.0.1/pfund_plot/widgets/ticker_widget.py +0 -82
  61. pfund_plot-0.0.1/pyproject.toml +0 -85
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright [2024] [Stephen Yau, PFund.ai]
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
@@ -0,0 +1,43 @@
1
+ Metadata-Version: 2.1
2
+ Name: pfund-plot
3
+ Version: 0.0.1.dev2
4
+ Summary: A wrapper of the existing plotting libraries for financial data analysis.
5
+ Home-page: https://pfund.ai
6
+ License: Apache-2.0
7
+ Keywords: trading,plotting,wrapper,pfund
8
+ Author: stephenyau
9
+ Author-email: softwareentrepreneer+pfund-plot@gmail.com
10
+ Requires-Python: >=3.10,<4.0
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: Intended Audience :: Financial and Insurance Industry
13
+ Classifier: Intended Audience :: Information Technology
14
+ Classifier: Intended Audience :: Science/Research
15
+ Classifier: License :: OSI Approved :: Apache Software License
16
+ Classifier: Operating System :: OS Independent
17
+ Classifier: Programming Language :: Python :: 3
18
+ Classifier: Programming Language :: Python :: 3.10
19
+ Classifier: Programming Language :: Python :: 3.11
20
+ Classifier: Programming Language :: Python :: 3.12
21
+ Classifier: Programming Language :: Python :: 3.13
22
+ Classifier: Topic :: Office/Business :: Financial :: Investment
23
+ Classifier: Topic :: Scientific/Engineering :: Visualization
24
+ Classifier: Topic :: Software Development :: Libraries
25
+ Provides-Extra: all
26
+ Provides-Extra: app
27
+ Provides-Extra: big-data
28
+ Requires-Dist: dash (>=2.18.1,<3.0.0) ; extra == "app" or extra == "all"
29
+ Requires-Dist: datashader (>=0.16.3,<0.17.0) ; extra == "big-data" or extra == "all"
30
+ Requires-Dist: great-tables (>=0.13.0,<0.14.0)
31
+ Requires-Dist: hvplot (>=0.11.1,<0.12.0) ; extra == "big-data" or extra == "all"
32
+ Requires-Dist: numba (>=0.60.0,<0.61.0) ; extra == "big-data" or extra == "all"
33
+ Requires-Dist: panel (>=1.5.2,<2.0.0) ; extra == "app" or extra == "all"
34
+ Requires-Dist: plotly (>=5.24.1,<6.0.0)
35
+ Requires-Dist: streamlit (>=1.39.0,<2.0.0) ; extra == "app" or extra == "all"
36
+ Requires-Dist: taipy (>=4.0.0,<5.0.0) ; extra == "app" or extra == "all"
37
+ Project-URL: Documentation, https://pfund-plot-docs.pfund.ai
38
+ Project-URL: Repository, https://github.com/PFund-Software-Ltd/pfund-plot
39
+ Description-Content-Type: text/markdown
40
+
41
+ # pfund-plot
42
+
43
+ A wrapper of the existing plotting libraries for financial data analysis.
@@ -0,0 +1,3 @@
1
+ # pfund-plot
2
+
3
+ A wrapper of the existing plotting libraries for financial data analysis.
@@ -0,0 +1 @@
1
+ import pfund_plot
@@ -0,0 +1,46 @@
1
+ [tool.poetry]
2
+ name = "pfund-plot"
3
+ version = "0.0.1.dev2"
4
+ description = "A wrapper of the existing plotting libraries for financial data analysis."
5
+ license = "Apache-2.0"
6
+ authors = ["stephenyau <softwareentrepreneer+pfund-plot@gmail.com>"]
7
+ readme = "README.md"
8
+ homepage = "https://pfund.ai"
9
+ repository = "https://github.com/PFund-Software-Ltd/pfund-plot"
10
+ documentation = "https://pfund-plot-docs.pfund.ai"
11
+ keywords = ["trading", "plotting", "wrapper", "pfund"]
12
+ classifiers = [
13
+ "Operating System :: OS Independent",
14
+ "Intended Audience :: Developers",
15
+ "Intended Audience :: Science/Research",
16
+ "Intended Audience :: Financial and Insurance Industry",
17
+ "Intended Audience :: Information Technology",
18
+ "Topic :: Office/Business :: Financial :: Investment",
19
+ "Topic :: Scientific/Engineering :: Visualization",
20
+ "Topic :: Software Development :: Libraries",
21
+ "Programming Language :: Python :: 3.10",
22
+ "Programming Language :: Python :: 3.11",
23
+ "Programming Language :: Python :: 3.12",
24
+ "Programming Language :: Python :: 3.13",
25
+ ]
26
+
27
+ [tool.poetry.dependencies]
28
+ python = "^3.10"
29
+ plotly = "^5.24.1"
30
+ great-tables = "^0.13.0"
31
+ hvplot = {version = "^0.11.1", optional = true}
32
+ numba = {version = "^0.60.0", optional = true} # TEMP, remove it when datashader has fixed the llvmlite install issue
33
+ datashader = {version = "^0.16.3", optional = true}
34
+ dash = {version = "^2.18.1", optional = true}
35
+ taipy = {version = "^4.0.0", optional = true}
36
+ panel = {version = "^1.5.2", optional = true}
37
+ streamlit = {version = "^1.39.0", optional = true}
38
+
39
+ [tool.poetry.extras]
40
+ big-data = ["hvplot", "numba", "datashader"] # need numba to get around llvmlite install issue when installing datashader
41
+ app = ["dash", "taipy", "panel", "streamlit"]
42
+ all = ["hvplot", "numba", "datashader", "dash", "taipy", "panel", "streamlit"]
43
+
44
+ [build-system]
45
+ requires = ["poetry-core"]
46
+ build-backend = "poetry.core.masonry.api"
pfund_plot-0.0.1/PKG-INFO DELETED
@@ -1,148 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: pfund-plot
3
- Version: 0.0.1
4
- Summary: A library for financial data visualization, dashboard creation, and template sharing.
5
- Keywords: financial data,plotting,dashboards,charts,data visualization,graphs,plots
6
- Author: Stephen Yau
7
- Author-email: Stephen Yau <softwareentrepreneer+pfund-plot@gmail.com>
8
- License-Expression: Apache-2.0
9
- Classifier: Operating System :: OS Independent
10
- Classifier: Intended Audience :: Developers
11
- Classifier: Intended Audience :: Science/Research
12
- Classifier: Intended Audience :: Financial and Insurance Industry
13
- Classifier: Intended Audience :: Information Technology
14
- Classifier: Topic :: Office/Business :: Financial :: Investment
15
- Classifier: Topic :: Scientific/Engineering :: Visualization
16
- Classifier: Topic :: Software Development :: Libraries
17
- Classifier: Typing :: Typed
18
- Classifier: Programming Language :: Python :: 3.11
19
- Classifier: Programming Language :: Python :: 3.12
20
- Classifier: Programming Language :: Python :: 3.13
21
- Requires-Dist: pfeed>=0.0.15
22
- Requires-Dist: panel>=1.9.3
23
- Requires-Dist: hvplot>=0.12.2
24
- Requires-Dist: dayplot>=0.5.1
25
- Requires-Dist: anywidget>=0.11.0 ; sys_platform != 'emscripten'
26
- Requires-Dist: ipywidgets-bokeh>=1.7.0 ; sys_platform != 'emscripten'
27
- Requires-Dist: pywebview>=6.2.1 ; sys_platform != 'emscripten'
28
- Requires-Dist: datashader>=0.19.1 ; sys_platform != 'emscripten'
29
- Requires-Dist: altair>=6.1.0 ; extra == 'altair'
30
- Requires-Dist: vegafusion>=2.0.3 ; extra == 'altair'
31
- Requires-Dist: vl-convert-python>=1.9.0.post1 ; extra == 'altair'
32
- Requires-Dist: jupyter-bokeh>=4.0.5 ; extra == 'jupyter'
33
- Requires-Dist: notebook>=7.5.7 ; extra == 'jupyter'
34
- Requires-Dist: papermill>=2.7.0 ; extra == 'jupyter'
35
- Requires-Dist: voila>=0.5.12 ; extra == 'jupyter'
36
- Requires-Dist: marimo[recommended,lsp]>=0.23.9 ; extra == 'marimo'
37
- Requires-Dist: matplotlib>=3.10.9 ; extra == 'matplotlib'
38
- Requires-Dist: plotly>=6.8.0 ; extra == 'plotly'
39
- Requires-Python: >=3.11
40
- Project-URL: homepage, https://pfund-plot.pfund.ai
41
- Project-URL: repository, https://github.com/PFund-Software-Ltd/pfund-plot
42
- Project-URL: documentation, https://pfund-plot.pfund.ai/doc
43
- Provides-Extra: altair
44
- Provides-Extra: jupyter
45
- Provides-Extra: marimo
46
- Provides-Extra: matplotlib
47
- Provides-Extra: plotly
48
- Description-Content-Type: text/markdown
49
-
50
- # PFund-Plot: Financial Charts in One Line of Code
51
-
52
- [![Discord](https://img.shields.io/badge/Discord-%235865F2.svg?logo=discord&logoColor=white)](https://discord.gg/vqpS94tpdp)
53
- [![X](https://img.shields.io/twitter/follow/pfund_ai?style=social)](https://x.com/pfund_ai)
54
- [![Downloads](https://static.pepy.tech/badge/pfund-plot/month)](https://pepy.tech/project/pfund-plot)
55
- [![PyPI](https://img.shields.io/pypi/v/pfund-plot.svg?cacheSeconds=300)](https://pypi.org/project/pfund-plot)
56
- ![PyPI - Support Python Versions](https://img.shields.io/pypi/pyversions/pfund-plot?cacheSeconds=300)
57
- [![afterpython](https://afterpython.org/shield.svg)](https://afterpython.org)
58
- [![Discussions](https://img.shields.io/badge/Discussions-Let's%20Chat-green)](https://github.com/PFund-Software-Ltd/pfund-plot/discussions)
59
- [![Jupyter Notebook](https://img.shields.io/badge/jupyter-notebook-orange?logo=jupyter)](https://jupyter.org)
60
- [![Marimo](https://marimo.io/shield.svg)](https://marimo.io)
61
- [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/PFund-Software-Ltd/pfund-plot)
62
- [![View Code Wiki](https://assets.codewiki.google/readme-badge/static.svg)](https://codewiki.google/github.com/pfund-software-ltd/pfund-plot?utm_source=badge&utm_medium=github&utm_campaign=github.com/pfund-software-ltd/pfund-plot)
63
- <!-- ![PyPI downloads](https://img.shields.io/pypi/dm/pfund-plot?label=downloads&cacheSeconds=86400) -->
64
- <!-- ![GitHub stars](https://img.shields.io/github/stars/PFund-Software-Ltd/pfund-plot?style=social) -->
65
-
66
-
67
- > **This library is NOT ready for use, please wait for 0.1.0 release.**
68
-
69
- ## TL;DR: pfund-plot handles the plotting libraries, so traders just get charts that work
70
-
71
- ## Problem
72
- Traders often need to quickly visualize their data without investing time in learning new tools.
73
- For example, plotting a candlestick should be as simple as writing a single line of code.
74
-
75
- ## Solution
76
- We created a high-level financial visualization layer that combines the best features from existing plotting libraries into an easy-to-use interface.
77
-
78
- ---
79
- <img src="afterpython/static/candlestick.gif" alt="pfund-plot candlestick streaming example" width="450">
80
-
81
- ---
82
-
83
- `pfund-plot` is a financial visualization layer on top of existing plotting libraries, giving traders a simple, domain-specific interface for plotting and streaming market data.
84
-
85
- ## Core Features
86
- - [x] Multi-Display Mode: support displaying plots in a *Jupyter notebook*, *Marimo notebook*, *browser* and *desktop window*
87
- - [x] Intuitive & Chainable API: `plt.ohlc(df).style(...).control(...).mode(...).show()`
88
- - [x] Streaming Plots: support streaming data in real-time
89
- - [x] DataFrame Agnostic: support pandas, polars, and dask
90
- - [x] Financial Plots: plot financial data by just one function call
91
- - [x] Combine multiple plots into a dashboard quickly for visualization
92
-
93
-
94
- ## Installation
95
- ```bash
96
- pip install pfund-plot
97
- ```
98
-
99
- ## Quickstart
100
- ### 1. Plotting in a Jupyter or Marimo Notebook
101
- > To use data sources other than Bybit, please go to [pfeed](https://github.com/PFund-Software-Ltd/pfeed) and install the corresponding extras. For example: `pip install "pfeed[data_source1, data_source2]"`
102
- ```python
103
- import pfeed as pe
104
- import pfund_plot as plt
105
-
106
- feed = pe.Bybit().market_feed
107
- result = feed.download(product='BTC_USDT_PERP', resolution='1h', rollback_period='1d')
108
- df = result.data.collect()
109
-
110
- # Notebook mode:
111
- plt.ohlc(df)
112
- ```
113
-
114
- ### 2. Plotting in a Python Script
115
- ```python
116
- # Browser mode:
117
- plt.ohlc(df).mode('browser').show()
118
-
119
- # Desktop mode:
120
- if __name__ == "__main__": # Required because desktop mode uses multiprocessing.
121
- plt.ohlc(df).mode('desktop').show()
122
- ```
123
-
124
- ### 3. Streaming a Plot
125
- ```python
126
- # Streaming requires pipeline_mode=True.
127
- feed = pe.Bybit(pipeline_mode=True).market_feed
128
- feed.stream(product='BTC_USDT_PERP', resolution='1s')
129
-
130
- # In a Python script:
131
- plt.ohlc(feed).control(update_interval=1000).mode('browser') # or mode('desktop') under if __name__ == "__main__"
132
-
133
- # In a notebook environment (not recommended to start streaming in a notebook unless you know what you're doing):
134
- # await plt.ohlc(feed).control(update_interval=1000).show_async()
135
- ```
136
-
137
- ---
138
-
139
- ## Tapping into the JavaScript World
140
- Python developers sometimes envy the JavaScript visualization ecosystem for its rich set of interactive charts and dashboards. With `pfund-plot`, they can still enjoy the benefits of the JavaScript world while keeping the same Python-first API. For example:
141
- ```python
142
- plt.ohlc(df).backend('svelte')
143
- ```
144
- This renders the following chart using TradingView's [Lightweight Charts](https://github.com/tradingview/lightweight-charts):
145
-
146
- <img src="afterpython/static/tradingview.png" alt="pfund-plot TradingView Lightweight Charts example" width="450">
147
-
148
- > This is meant as a showcase rather than a core direction: `pfund-plot` remains Python-first, and JavaScript-backed charts are supported where they fit naturally. If you want to bring more useful JavaScript visualizations into `pfund-plot`, contributions are welcome.
@@ -1,99 +0,0 @@
1
- # PFund-Plot: Financial Charts in One Line of Code
2
-
3
- [![Discord](https://img.shields.io/badge/Discord-%235865F2.svg?logo=discord&logoColor=white)](https://discord.gg/vqpS94tpdp)
4
- [![X](https://img.shields.io/twitter/follow/pfund_ai?style=social)](https://x.com/pfund_ai)
5
- [![Downloads](https://static.pepy.tech/badge/pfund-plot/month)](https://pepy.tech/project/pfund-plot)
6
- [![PyPI](https://img.shields.io/pypi/v/pfund-plot.svg?cacheSeconds=300)](https://pypi.org/project/pfund-plot)
7
- ![PyPI - Support Python Versions](https://img.shields.io/pypi/pyversions/pfund-plot?cacheSeconds=300)
8
- [![afterpython](https://afterpython.org/shield.svg)](https://afterpython.org)
9
- [![Discussions](https://img.shields.io/badge/Discussions-Let's%20Chat-green)](https://github.com/PFund-Software-Ltd/pfund-plot/discussions)
10
- [![Jupyter Notebook](https://img.shields.io/badge/jupyter-notebook-orange?logo=jupyter)](https://jupyter.org)
11
- [![Marimo](https://marimo.io/shield.svg)](https://marimo.io)
12
- [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/PFund-Software-Ltd/pfund-plot)
13
- [![View Code Wiki](https://assets.codewiki.google/readme-badge/static.svg)](https://codewiki.google/github.com/pfund-software-ltd/pfund-plot?utm_source=badge&utm_medium=github&utm_campaign=github.com/pfund-software-ltd/pfund-plot)
14
- <!-- ![PyPI downloads](https://img.shields.io/pypi/dm/pfund-plot?label=downloads&cacheSeconds=86400) -->
15
- <!-- ![GitHub stars](https://img.shields.io/github/stars/PFund-Software-Ltd/pfund-plot?style=social) -->
16
-
17
-
18
- > **This library is NOT ready for use, please wait for 0.1.0 release.**
19
-
20
- ## TL;DR: pfund-plot handles the plotting libraries, so traders just get charts that work
21
-
22
- ## Problem
23
- Traders often need to quickly visualize their data without investing time in learning new tools.
24
- For example, plotting a candlestick should be as simple as writing a single line of code.
25
-
26
- ## Solution
27
- We created a high-level financial visualization layer that combines the best features from existing plotting libraries into an easy-to-use interface.
28
-
29
- ---
30
- <img src="afterpython/static/candlestick.gif" alt="pfund-plot candlestick streaming example" width="450">
31
-
32
- ---
33
-
34
- `pfund-plot` is a financial visualization layer on top of existing plotting libraries, giving traders a simple, domain-specific interface for plotting and streaming market data.
35
-
36
- ## Core Features
37
- - [x] Multi-Display Mode: support displaying plots in a *Jupyter notebook*, *Marimo notebook*, *browser* and *desktop window*
38
- - [x] Intuitive & Chainable API: `plt.ohlc(df).style(...).control(...).mode(...).show()`
39
- - [x] Streaming Plots: support streaming data in real-time
40
- - [x] DataFrame Agnostic: support pandas, polars, and dask
41
- - [x] Financial Plots: plot financial data by just one function call
42
- - [x] Combine multiple plots into a dashboard quickly for visualization
43
-
44
-
45
- ## Installation
46
- ```bash
47
- pip install pfund-plot
48
- ```
49
-
50
- ## Quickstart
51
- ### 1. Plotting in a Jupyter or Marimo Notebook
52
- > To use data sources other than Bybit, please go to [pfeed](https://github.com/PFund-Software-Ltd/pfeed) and install the corresponding extras. For example: `pip install "pfeed[data_source1, data_source2]"`
53
- ```python
54
- import pfeed as pe
55
- import pfund_plot as plt
56
-
57
- feed = pe.Bybit().market_feed
58
- result = feed.download(product='BTC_USDT_PERP', resolution='1h', rollback_period='1d')
59
- df = result.data.collect()
60
-
61
- # Notebook mode:
62
- plt.ohlc(df)
63
- ```
64
-
65
- ### 2. Plotting in a Python Script
66
- ```python
67
- # Browser mode:
68
- plt.ohlc(df).mode('browser').show()
69
-
70
- # Desktop mode:
71
- if __name__ == "__main__": # Required because desktop mode uses multiprocessing.
72
- plt.ohlc(df).mode('desktop').show()
73
- ```
74
-
75
- ### 3. Streaming a Plot
76
- ```python
77
- # Streaming requires pipeline_mode=True.
78
- feed = pe.Bybit(pipeline_mode=True).market_feed
79
- feed.stream(product='BTC_USDT_PERP', resolution='1s')
80
-
81
- # In a Python script:
82
- plt.ohlc(feed).control(update_interval=1000).mode('browser') # or mode('desktop') under if __name__ == "__main__"
83
-
84
- # In a notebook environment (not recommended to start streaming in a notebook unless you know what you're doing):
85
- # await plt.ohlc(feed).control(update_interval=1000).show_async()
86
- ```
87
-
88
- ---
89
-
90
- ## Tapping into the JavaScript World
91
- Python developers sometimes envy the JavaScript visualization ecosystem for its rich set of interactive charts and dashboards. With `pfund-plot`, they can still enjoy the benefits of the JavaScript world while keeping the same Python-first API. For example:
92
- ```python
93
- plt.ohlc(df).backend('svelte')
94
- ```
95
- This renders the following chart using TradingView's [Lightweight Charts](https://github.com/tradingview/lightweight-charts):
96
-
97
- <img src="afterpython/static/tradingview.png" alt="pfund-plot TradingView Lightweight Charts example" width="450">
98
-
99
- > This is meant as a showcase rather than a core direction: `pfund-plot` remains Python-first, and JavaScript-backed charts are supported where they fit naturally. If you want to bring more useful JavaScript visualizations into `pfund-plot`, contributions are welcome.