Skip to content
This repository was archived by the owner on Jun 3, 2024. It is now read-only.

Commit ceba689

Browse files
Merge pull request #117 from plotly/final
re-export plotly.express
2 parents 1d2732c + 3887cea commit ceba689

23 files changed

+17
-4147
lines changed

README.md

+4-10
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
# Plotly Express
22

3-
Plotly Express is a terse, consistent, high-level wrapper around [Plotly.py](https://plot.ly/python) for rapid data exploration and figure generation.
4-
5-
Documentation and examples can be found at https://plotly.express/
3+
Plotly Express is now part of Plotly.py version 4 and so the `plotly_express` module now just re-exports the contents of `plotly.express`
64

75
## Installation
86

9-
Plotly Express is compatible with Python 3+ and Python 2.7.
7+
You can just follow the [`plotly` Getting Started](https://plot.ly/python/getting-started/) instructions for installation and get access to `plotly.express` that way. If you have existing code that imports from `plotly_express` explicitly and you don't wish to change it, you can still install the latest version, which just exposes `plotly.express` under the `plotly_express` namespace.
108

119
### Via `pip`
1210

@@ -16,10 +14,6 @@ Just running `pip install plotly_express` in your terminal should do it!
1614

1715
You'll have to install from the `plotly` channel with `conda install -c plotly plotly_express`
1816

19-
### Running in JupyterLab
20-
21-
Using Plotly Express in JupyterLab requires the [`plotly-extension`](https://github.com/jupyterlab/jupyter-renderers/tree/master/packages/plotly-extension) to be installed by running `jupyter labextension install @jupyterlab/plotly-extension`.
22-
23-
## Troubleshooting
17+
## Getting Help
2418

25-
Plotly Express depends on very recent versions of `plotly` and it's sometimes possible to get into a state where you have multiple versions of `plotly` installed (e.g. once with `pip` and once with `conda`) so be sure to check your version by running `plotly.__version__` in the same environment that you're having issues with `plotly_express`.
19+
Please join our [Community Forum](https://community.plot.ly/c/api/python) or file a [Github Issue](https://github.com/plotly/plotly.py/issues/new) if you've found a bug.

gallery.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -189,18 +189,18 @@ px.line_3d(election, x="Joly", y="Coderre", z="Bergeron", color="winner", line_d
189189
## Polar Coordinates
190190

191191
```python
192-
px.scatter_polar(wind, r="value", theta="direction", color="strength", symbol="strength",
193-
color_discrete_sequence=px.colors.sequential.Plotly[-2::-1])
192+
px.scatter_polar(wind, r="frequency", theta="direction", color="strength", symbol="strength",
193+
color_discrete_sequence=px.colors.sequential.Plasma[-2::-1])
194194
```
195195

196196
```python
197-
px.line_polar(wind, r="value", theta="direction", color="strength", line_close=True,
198-
color_discrete_sequence=px.colors.sequential.Plotly[-2::-1])
197+
px.line_polar(wind, r="frequency", theta="direction", color="strength", line_close=True,
198+
color_discrete_sequence=px.colors.sequential.Plasma[-2::-1])
199199
```
200200

201201
```python
202-
px.bar_polar(wind, r="value", theta="direction", color="strength", template="plotly_dark",
203-
color_discrete_sequence= px.colors.sequential.Plotly[-2::-1])
202+
px.bar_polar(wind, r="frequency", theta="direction", color="strength", template="plotly_dark",
203+
color_discrete_sequence= px.colors.sequential.Plasma[-2::-1])
204204
```
205205

206206
## Maps

plotly_express/__init__.py

+4-71
Original file line numberDiff line numberDiff line change
@@ -1,75 +1,8 @@
11
"""
2-
`plotly_express` is a terse, consistent, high-level wrapper around `plotly` for rapid \
3-
data exploration and figure generation. See the gallery at https://plotly.github.io/plotly_express
2+
`plotly_express` is now an alias to `plotly.express`
43
"""
54

6-
__version__ = "0.3.1"
5+
__version__ = "0.4.0"
76

8-
from ._chart_types import ( # noqa: F401
9-
scatter,
10-
scatter_3d,
11-
scatter_polar,
12-
scatter_ternary,
13-
scatter_mapbox,
14-
scatter_geo,
15-
line,
16-
line_3d,
17-
line_polar,
18-
line_ternary,
19-
line_mapbox,
20-
line_geo,
21-
area,
22-
bar,
23-
bar_polar,
24-
violin,
25-
box,
26-
strip,
27-
histogram,
28-
scatter_matrix,
29-
parallel_coordinates,
30-
parallel_categories,
31-
choropleth,
32-
density_contour,
33-
density_heatmap,
34-
)
35-
36-
from ._core import ( # noqa: F401
37-
ExpressFigure,
38-
set_mapbox_access_token,
39-
defaults,
40-
get_trendline_results,
41-
)
42-
43-
from . import data, colors # noqa: F401
44-
45-
__all__ = [
46-
"scatter",
47-
"scatter_3d",
48-
"scatter_polar",
49-
"scatter_ternary",
50-
"scatter_mapbox",
51-
"scatter_geo",
52-
"scatter_matrix",
53-
"density_contour",
54-
"density_heatmap",
55-
"line",
56-
"line_polar",
57-
"line_ternary",
58-
"line_mapbox",
59-
"line_geo",
60-
"parallel_coordinates",
61-
"parallel_categories",
62-
"area",
63-
"bar",
64-
"bar_polar",
65-
"violin",
66-
"box",
67-
"strip",
68-
"histogram",
69-
"choropleth",
70-
"data",
71-
"colors",
72-
"set_mapbox_access_token",
73-
"get_trendline_results",
74-
"ExpressFigure",
75-
]
7+
from plotly.express import *
8+
from plotly.express import line_3d

0 commit comments

Comments
 (0)