Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions doc/python/3d-mesh.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ import plotly.graph_objects as go
import numpy as np

# Download data set from plotly repo
pts = np.loadtxt(np.DataSource().open('https://raw.githubusercontent.com/plotly/datasets/master/mesh_dataset.txt'))
pts = np.loadtxt(np.lib.npyio.DataSource().open('https://raw.githubusercontent.com/plotly/datasets/master/mesh_dataset.txt'))
x, y, z = pts.T

fig = go.Figure(data=[go.Mesh3d(x=x, y=y, z=z, color='lightpink', opacity=0.50)])
Expand All @@ -58,7 +58,7 @@ The `alphahull` parameter sets the shape of the mesh. If the value is -1 (defaul
import plotly.graph_objects as go
import numpy as np

pts = np.loadtxt(np.DataSource().open('https://raw.githubusercontent.com/plotly/datasets/master/mesh_dataset.txt'))
pts = np.loadtxt(np.lib.npyio.DataSource().open('https://raw.githubusercontent.com/plotly/datasets/master/mesh_dataset.txt'))
x, y, z = pts.T

fig = go.Figure(data=[go.Mesh3d(x=x, y=y, z=z,
Expand Down
8 changes: 4 additions & 4 deletions doc/python/colorscales.md
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ fig.show()
```python
import plotly.graph_objects as go

import urllib
import urllib.request
import json

response = urllib.request.urlopen(
Expand Down Expand Up @@ -535,7 +535,7 @@ Like axes, you can customize the color bar ticks, labels, and values with `ticks
```python
import plotly.graph_objects as go

import urllib
import urllib.request
import json

# Load heatmap data
Expand Down Expand Up @@ -570,7 +570,7 @@ By default, color bars are displayed vertically. You can change a color bar to b
```python
import plotly.graph_objects as go

import urllib
import urllib.request
import json

# Load heatmap data
Expand Down Expand Up @@ -647,7 +647,7 @@ See the positioning section of [the figure data structure page](/python/figure-s
```python
import plotly.graph_objects as go

import urllib
import urllib.request
import json

# Load heatmap data
Expand Down
2 changes: 1 addition & 1 deletion doc/python/graphing-multiple-chart-types.md
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ import plotly.graph_objects as go

# Load data
import json
import urllib
import urllib.request

response = urllib.request.urlopen(
"https://raw.githubusercontent.com/plotly/datasets/master/steepest.json")
Expand Down
4 changes: 2 additions & 2 deletions doc/python/sankey-diagram.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ fig.show()

```python
import plotly.graph_objects as go
import urllib, json
import urllib.request, json

url = 'https://raw.githubusercontent.com/plotly/plotly.js/master/test/image/mocks/sankey_energy.json'
response = urllib.request.urlopen(url)
Expand Down Expand Up @@ -126,7 +126,7 @@ This example also uses [hovermode](https://plotly.com/python/reference/layout/#l

```python
import plotly.graph_objects as go
import urllib, json
import urllib.request, json

url = 'https://raw.githubusercontent.com/plotly/plotly.js/master/test/image/mocks/sankey_energy.json'
response = urllib.request.urlopen(url)
Expand Down
Loading