Skip to content

Commit 0768685

Browse files
committed
update titles as strings
1 parent 034a47b commit 0768685

File tree

4 files changed

+15
-6
lines changed

4 files changed

+15
-6
lines changed

Diff for: doc/python/county-choropleth.md

+8-1
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,14 @@ fig = ff.create_choropleth(
120120
fips=fips, values=values, scope=['CA', 'AZ', 'Nevada', 'Oregon', ' Idaho'],
121121
binning_endpoints=[14348, 63983, 134827, 426762, 2081313], colorscale=colorscale,
122122
county_outline={'color': 'rgb(255,255,255)', 'width': 0.5}, round_legend_values=True,
123-
legend_title='Population by County', title='California and Nearby States'
123+
legend=dict(
124+
title=dict(
125+
text='Population by County'
126+
)
127+
),
128+
title=dict(
129+
text='California and Nearby States'
130+
)
124131
)
125132
fig.layout.template = None
126133
fig.show()

Diff for: doc/python/pandas-backend.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ import pandas as pd
5555
pd.options.plotting.backend = "plotly"
5656

5757
df = pd.DataFrame(dict(a=[1,3,2], b=[3,2,1]))
58-
fig = df.plot(title="Pandas Backend Example", template="simple_white",
58+
fig = df.plot(title=dict(text="Pandas Backend Example"), template="simple_white",
5959
labels=dict(index="time", value="money", variable="option"))
6060
fig.update_yaxes(tickprefix="$")
6161
fig.show()

Diff for: doc/python/ternary-contour.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,9 @@ fig = ff.create_ternary_contour(np.array([Al, Y, Cu]), enthalpy,
7676
ncontours=20,
7777
colorscale='Viridis',
7878
showscale=True,
79-
title='Mixing enthalpy of ternary alloy')
79+
title=dict(
80+
text='Mixing enthalpy of ternary alloy'
81+
))
8082
fig.show()
8183
```
8284

Diff for: doc/python/trisurf.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ simplices = tri.simplices
5959

6060
fig = ff.create_trisurf(x=x, y=y, z=z,
6161
simplices=simplices,
62-
title="Torus", aspectratio=dict(x=1, y=1, z=0.3))
62+
title=dict(text="Torus"), aspectratio=dict(x=1, y=1, z=0.3))
6363
fig.show()
6464
```
6565

@@ -90,7 +90,7 @@ simplices = tri.simplices
9090
fig = ff.create_trisurf(x=x, y=y, z=z,
9191
colormap="Portland",
9292
simplices=simplices,
93-
title="Mobius Band")
93+
title=dict(text="Mobius Band"))
9494
fig.show()
9595
```
9696

@@ -122,7 +122,7 @@ fig = ff.create_trisurf(x=x, y=y, z=z,
122122
colormap=['rgb(50, 0, 75)', 'rgb(200, 0, 200)', '#c8dcc8'],
123123
show_colorbar=True,
124124
simplices=simplices,
125-
title="Boy's Surface")
125+
title=dict(text="Boy's Surface"))
126126
fig.show()
127127
```
128128

0 commit comments

Comments
 (0)