-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Closed
Description
I have plotly 4.1.0 installed and this code (in a Jupyter Notebook):
import numpy as np
import plotly.offline as py
import plotly.graph_objs as go
matrix = np.random.randn(10, 10)
ticks = ["tick %i" % i for i in range(10)]
data = [go.Heatmap(z=matrix, x=ticks, y=ticks, colorscale='Viridis')]
layout = go.Layout(
hovermode='closest',
autosize=True,
xaxis=dict(zeroline=False),
yaxis=dict(zeroline=False, autorange='reversed', scaleanchor="x", scaleratio=1)
)
fig = go.Figure(data=data, layout=layout)
py.iplot(fig)
I think there really shouldn't be this space between the y ticks and colorbar and the heatmap. Without the yaxis scaleanchor="x"
it looks fine, but I really want a square heatmap... Is there any setting I'm missing or is this a bug?
Thanks!
Metadata
Metadata
Assignees
Labels
No labels