How to change plotly figure size

Have you considered to use

fig.update_layout(
    autosize=False,
    width=800,
    height=800,)

and eventually reduce the size of your marker?

UPDATE

Full Code

import plotly.graph_objs as go

trace1 = go.Scatter(
    x=x1_tsne,           # x-coordinates of trace
    y=y1_tsne,          # y-coordinates of trace
    mode="markers +text ",   # scatter mode (more in UG section 1)
    text = label3,
    opacity = 1,
    textposition='top center',

    marker = dict(size = 12, color = color_4, symbol = marker_list_2, line=dict(width=0.5)),
     textfont=dict(
        color="black",
        size=18, #can change the size of font here
        family='Times New Roman'
     )

    )
data = [trace1]

layout = go.Layout(
    autosize=False,
    width=1000,
    height=1000,

    xaxis= go.layout.XAxis(linecolor="black",
                          linewidth = 1,
                          mirror = True),

    yaxis= go.layout.YAxis(linecolor="black",
                          linewidth = 1,
                          mirror = True),

    margin=go.layout.Margin(
        l=50,
        r=50,
        b=100,
        t=100,
        pad = 4
    )
)

fig = go.Figure(data=data, layout=layout)

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)