Skip to content

Commit 5334bf0

Browse files
committed
Merge remote-tracking branch 'upstream/master' into doc-histogram-categoryorder
2 parents 2a2ee8b + 234ec0d commit 5334bf0

File tree

429 files changed

+19604
-6910
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

429 files changed

+19604
-6910
lines changed

.circleci/config.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -440,6 +440,15 @@ jobs:
440440
git push --force [email protected]:plotly/plotly.py-docs.git master:built
441441
rm -rf .git
442442
cd ../..
443+
cd build/ipynb
444+
git init
445+
git config user.name plotlydocbot
446+
git config user.email [email protected]
447+
git add *
448+
git commit -m "build of https://github.com/plotly/plotly.py/commit/${CIRCLE_SHA1}"
449+
git push --force [email protected]:plotly/plotly.py-docs.git master:built_ipynb
450+
rm -rf .git
451+
cd ../..
443452
fi
444453
tar -zcf build/html.tgz build/html
445454
rm -rf build/html build/ipynb

.gitattributes

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
plotly/_version.py export-subst
1+
packages/python/plotly/plotly/_version.py export-subst

.github/FUNDING.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
github: plotly
12
custom: https://plot.ly/products/consulting-and-oem/

.github/pull_request_template.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,5 +33,6 @@ below :-).
3333
- [ ] For a new feature, I have added documentation examples in an existing or
3434
new tutorial notebook (please see the doc checklist as well).
3535
- [ ] I have added a CHANGELOG entry if fixing/changing/adding anything substantial.
36+
- [ ] For a new feature or a change in behaviour, I have updated the relevant docstrings in the code to describe the feature or behaviour (please see the doc checklist as well).
3637
3738
-->

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ node_modules/
3131

3232
# virtual envs
3333
vv
34-
venv
34+
venv*
3535

3636
# dist files
3737
build
@@ -46,4 +46,5 @@ temp-plot.html
4646
doc/python/.ipynb_checkpoints
4747
doc/python/.mapbox_token
4848
doc/.ipynb_checkpoints
49+
tags
4950
doc/check-or-enforce-order.py

CHANGELOG.md

Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,108 @@
22
All notable changes to this project will be documented in this file.
33
This project adheres to [Semantic Versioning](http://semver.org/).
44

5+
## [4.15.0] - UNRELEASED
6+
7+
### Added
8+
9+
### Fixed
10+
11+
### Updated
12+
13+
14+
## [4.14.2] - UNRELEASED
15+
16+
### Added
17+
18+
### Fixed
19+
20+
### Updated
21+
22+
23+
## [4.14.1] - 2020-12-09
24+
25+
### Updated
26+
27+
- Updated Plotly.js to version 1.58.2. See the [plotly.js CHANGELOG](https://github.com/plotly/plotly.js/blob/v1.58.0/CHANGELOG.md) for more information. These changes are reflected in the auto-generated `plotly.graph_objects` module. Notable changes include:
28+
- fixes for new `ticklabelposition` attribute
29+
- fixes for a regression related to treemaps in the previous version
30+
31+
32+
## [4.14.0] - 2020-12-07
33+
34+
### Added
35+
36+
- `px.imshow` now supports `facet_col` and `animation_frame` arguments for visualizing 3-d and 4-d images [2746](https://github.com/plotly/plotly.py/pull/2746)
37+
- `px.defaults` now supports `color_discrete_map`, `symbol_map`, `line_dash_map`, `labels` and `category_orders` as well as a `.reset()` method [2957](https://github.com/plotly/plotly.py/pull/2957)
38+
39+
### Fixed
40+
41+
- axes will now auto-type numeric strings as categorical data rather than linear in the default templates [2951](https://github.com/plotly/plotly.py/pull/2951)
42+
43+
### Updated
44+
45+
- Updated Plotly.js to version 1.58.1. See the [plotly.js CHANGELOG](https://github.com/plotly/plotly.js/blob/v1.58.0/CHANGELOG.md) for more information. These changes are reflected in the auto-generated `plotly.graph_objects` module. Notable changes include:
46+
- a new `ticklabelposition` attribute to enable positioning tick labels inside the plotting area
47+
- better support for `scaleanchor` and `matches` on cartesian axes for matched square subplots
48+
- a new `autotypenumbers` attribute which is now set to `strict` in the default templates
49+
- various fixes relating to `automargins` for small figures
50+
51+
52+
## [4.13.0] - 2020-11-23
53+
54+
### Added
55+
- `px.choropleth`, `px.scatter_geo` and `px.line_geo` now support faceting as well as `fitbounds` and `basemap_visible` [2923](https://github.com/plotly/plotly.py/pull/2923)
56+
- `px.scatter_geo` and `px.line_geo` now support `geojson`/`featureidkey` input [2923](https://github.com/plotly/plotly.py/pull/2923)
57+
- `px.scatter_geo` now supports `symbol` [2923](https://github.com/plotly/plotly.py/pull/2923)
58+
- `go.Figure` now has a `set_subplots` method to set subplots on an already
59+
existing figure. [2866](https://github.com/plotly/plotly.py/pull/2866)
60+
- Added `Turbo` colorscale and fancier swatch display functions
61+
[2882](https://github.com/plotly/plotly.py/pull/2882)
62+
- A utility function `image_array_to_data_uri` has been added in
63+
`plotly.utils`, in order to transform NumPy arrays to data b64 URIs (which
64+
can be passed to the source parameter of `go.Image`, or to layout images).
65+
[2879](https://github.com/plotly/plotly.py/pull/2879)
66+
- the `selector` argument to updater/selector functions now accepts `int`s and `str`s
67+
[2894](https://github.com/plotly/plotly.py/pull/2894)
68+
69+
70+
### Updated
71+
72+
- the JSON serialization of plotly figures has been accelerated thanks to a
73+
different handling of Infinity and NaN values. For example, a figure with a
74+
1000x1000 Heatmap should now serialize 2x faster. [2880](https://github.com/plotly/plotly.py/pull/2880)
75+
- Coding mistakes with "magic underscores" now return significantly more ergonomic error
76+
messages [2843](https://github.com/plotly/plotly.py/pull/2843)
77+
- Error messages related to impossible subplot geometries are now much more helpful
78+
[2897](https://github.com/plotly/plotly.py/pull/2897)
79+
80+
81+
### Fixed
82+
83+
- `px.scatter_geo` support for `text` is fixed [2923](https://github.com/plotly/plotly.py/pull/2923)
84+
- the `x` and `y` parameters of `px.imshow` are now used also in the case where
85+
an Image trace is used (for RGB data or with `binary_string=True`). However,
86+
only numerical values are accepted (while the Heatmap trace allows date or
87+
string values for `x` and `y`). [2761](https://github.com/plotly/plotly.py/pull/2761)
88+
89+
90+
## [4.12.0] - 2020-10-23
91+
92+
### Added
93+
94+
- For `add_trace`, `add_shape`, `add_annotation` and `add_layout_image`, the `row` and/or `col` argument now also accept the string `"all"`. `row="all"` adds the object to all the subplot rows and `col="all"` adds the object to all the subplot columns. ([#2840](https://github.com/plotly/plotly.py/pull/2840))
95+
- Shapes that reference the plot axes in one dimension and the data in another dimension can be added with the new `add_hline`, `add_vline`, `add_hrect`, `add_vrect` functions, which also support the `row="all"` and `col="all"` arguments. ([#2840](https://github.com/plotly/plotly.py/pull/2840))
96+
- The `add_trace`, `add_shape`, `add_annotation`, `add_layout_image`, `add_hline`, `add_vline`, `add_hrect`, `add_vrect` functions accept an argument `exclude_empty_subplots` which if `True`, only adds the object to subplots already containing traces or layout objects. This is useful in conjunction with the `row="all"` and `col="all"` arguments. ([#2840](https://github.com/plotly/plotly.py/pull/2840))
97+
- For all `go.Figure` functions accepting a selector argument (e.g., `select_traces`), this argument can now also be a function which is passed each relevant graph object (in the case of `select_traces`, it is passed every trace in the figure). For graph objects where this function returns true, the graph object is included in the selection. ([#2844](https://github.com/plotly/plotly.py/pull/2844))
98+
99+
### Added
100+
101+
- Better magic underscore error messages. For example, `some_fig.update_layout(geo_ltaxis_showgrid=True)` shows `Bad property path:\ngeo_ltaxis_showgrid\n ^` and lists the valid properties for `geo`.
102+
103+
### Updated
104+
105+
- Updated Plotly.js to version 1.57.1. See the [plotly.js CHANGELOG](https://github.com/plotly/plotly.js/blob/v1.57.1/CHANGELOG.md) for more information. These changes are reflected in the auto-generated `plotly.graph_objects` module.
106+
5107
## [4.11.0] - 2020-10-01
6108

7109
### Updated
@@ -16,6 +118,11 @@ This project adheres to [Semantic Versioning](http://semver.org/).
16118

17119
### Updated
18120

121+
- The JSON serialization of plotly figures had been accelerated by handling
122+
differently figures with and without NaN and Inf values ([#2880](https://github.com/plotly/plotly.py/pull/2880)).
123+
124+
### Updated
125+
19126
- Updated Plotly.js to version 1.55.2. See the [plotly.js CHANGELOG](https://github.com/plotly/plotly.js/blob/v1.55.2/CHANGELOG.md) for more information. These changes are reflected in the auto-generated `plotly.graph_objects` module.
20127
- `px.imshow` has a new `binary_string` boolean argument, which passes the
21128
image data as a b64 binary string when True. Using binary strings allow for

README.md

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,13 @@
3131
</tr>
3232
</table>
3333

34+
## Data Science Workspaces
35+
36+
Our recommended IDE for Plotly’s Python graphing library is Dash Enterprise’s [Data Science Workspaces](https://plotly.com/dash/workspaces/), which has both Jupyter notebook and Python code file support.
37+
3438
## Quickstart
3539

36-
`pip install plotly==4.11.0`
40+
`pip install plotly==4.14.1`
3741

3842
Inside [Jupyter notebook](https://jupyter.org/install) (installable with `pip install "notebook>=5.3" "ipywidgets>=7.2"`):
3943

@@ -82,13 +86,13 @@ Built on top of [plotly.js](https://github.com/plotly/plotly.js), `plotly.py` is
8286
plotly.py may be installed using pip...
8387

8488
```
85-
pip install plotly==4.11.0
89+
pip install plotly==4.14.1
8690
```
8791

8892
or conda.
8993

9094
```
91-
conda install -c plotly plotly=4.11.0
95+
conda install -c plotly plotly=4.14.1
9296
```
9397

9498
### Jupyter Notebook Support
@@ -125,18 +129,18 @@ Then run the following commands to install the required JupyterLab extensions (n
125129

126130
```
127131
# Basic JupyterLab renderer support
128-
jupyter labextension install jupyterlab-plotly@4.11.0
132+
jupyter labextension install jupyterlab-plotly@4.14.1
129133
130134
# OPTIONAL: Jupyter widgets extension for FigureWidget support
131-
jupyter labextension install @jupyter-widgets/jupyterlab-manager plotlywidget@4.11.0
135+
jupyter labextension install @jupyter-widgets/jupyterlab-manager plotlywidget@4.14.1
132136
```
133137

134138
Please check out our [Troubleshooting guide](https://plotly.com/python/troubleshooting/) if you run into any problems with JupyterLab.
135139

136140
### Static Image Export
137141

138142
plotly.py supports [static image export](https://plotly.com/python/static-image-export/),
139-
using the either the [`kaleido`](https://github.com/plotly/Kaleido)
143+
using either the [`kaleido`](https://github.com/plotly/Kaleido)
140144
package (recommended, supported as of `plotly` version 4.9) or the [orca](https://github.com/plotly/orca)
141145
command line utility (legacy as of `plotly` version 4.9).
142146

@@ -152,7 +156,7 @@ $ pip install -U kaleido
152156
or conda.
153157

154158
```
155-
$ conda install -c plotly python-kaleido
159+
$ conda install -c conda-forge python-kaleido
156160
```
157161

158162
#### Orca
@@ -200,13 +204,13 @@ The `chart-studio` package can be used to upload plotly figures to Plotly's Char
200204
Studio Cloud or On-Prem service. This package can be installed using pip...
201205

202206
```
203-
pip install chart-studio==1.0.0
207+
pip install chart-studio==1.1.0
204208
```
205209

206210
or conda
207211

208212
```
209-
conda install -c plotly chart-studio=1.0.0
213+
conda install -c plotly chart-studio=1.1.0
210214
```
211215

212216
## Migration

binder/requirements.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
jupytext
2-
plotly==4.11.0
2+
plotly==4.14.1
33
jupyter
44
notebook
55
pandas==1.0.3
@@ -18,3 +18,4 @@ cufflinks==0.17.3
1818
kaleido
1919
scikit-learn
2020
umap-learn
21+
wget

contributing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ pytest packages/python/plotly/plotly/tests/test_core/
280280
pytest plotly/tests/test_plotly/test_plot.py
281281
```
282282

283-
or for a specfic test function
283+
or for a specific test function
284284

285285
```bash
286286
pytest plotly/tests/test_plotly/test_plot.py::test_function

doc/Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,15 @@ all: $(HTML_FILES) $(V3_REDIR_FILES) $(NEXT_REDIR_FILES)
2323

2424
$(IPYNB_DIR)/.mapbox_token: $(MD_DIR)/.mapbox_token
2525
@mkdir -p $(IPYNB_DIR)
26-
cd $(IPYNB_DIR) && ln -s ../../$<
26+
@echo "[symlink] .mapbox_token"
27+
@cd $(IPYNB_DIR) && ln -s ../../$<
2728

2829
$(IPYNB_FILES): $(IPYNB_DIR)/.mapbox_token
2930

3031
$(IPYNB_DIR)/%.ipynb: $(MD_DIR)/%.md
3132
@mkdir -p $(IPYNB_DIR)
3233
@echo "[jupytext] $<"
33-
@cat what_about_dash.md >> $<
34-
@jupytext $< --to notebook --quiet --output $@
34+
@cat $< what_about_dash.md | jupytext --to notebook --quiet --output $@
3535

3636
$(HTML_DIR)/2019-07-03-%.html: $(IPYNB_DIR)/%.ipynb
3737
@mkdir -p $(HTML_DIR)

0 commit comments

Comments
 (0)