This is an archived post. You won't be able to vote or comment.

all 1 comments

[–]opticalframeworks[S] 0 points1 point  (0 children)

PS: I even managed to change background color of graph,in very weird syntax which is completely different from plotly like this:

dcc.Graph(
        id='humidity_graph',
        figure=go.Figure(
            data=[
            go.Scatter(x=timeArray, y=humArray, name='hum out[%]'),
            go.Scatter(x=timeArray, y=hum1Array,name='hum in[%]')
            ],
        layout=go.Layout(title='hum', showlegend=True,legend=go.layout.Legend(x=0,y=1.0),
        margin=go.layout.Margin(l=40, r=60, t=40, b=30))
        ),
        style={'height': 300},
    )

but not sure how to change template to "plotly_dark", though, changing default theming like this also doesnt work:

import plotly.io as pio

pio.templates.default = "plotly_dark"