-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Closed
Labels
bugsomething brokensomething broken
Description
The height of plots stored in html via plotly.offline.plot
is set to 450px when height is not specified (at least in my test).
Example:
import numpy as np
import pandas as pd
import plotly
from plotly import graph_objs as go
from plotly.offline import plot
N = 1000
df = pd.DataFrame({
't': np.random.random(N),
'x': np.random.random(N),
'y': np.random.random(N)
})
traces = [
go.Scatter3d(
x=df['x'],
y=df['y'],
z=df['t'],
mode='markers',
marker=dict(size=1)
)
]
layout = go.Layout(
autosize=True,
scene=go.layout.Scene(
xaxis=go.layout.scene.XAxis(title='X'),
yaxis=go.layout.scene.YAxis(title='Y'),
zaxis=go.layout.scene.ZAxis(title='Time'),
)
)
fig = go.Figure(data=traces, layout=layout)
filename = f"demo.html"
plotly.offline.plot(fig, filename=filename, auto_open=False)
The picture below shows the entire browser page in Firefox 66.0.3
on macOS High Sierra 10.13.6
. The file looks the same in Chrome 73.0.3683.103
. I am using plotly 3.8.0
on Python 3.7
.
Metadata
Metadata
Assignees
Labels
bugsomething brokensomething broken