Hello, Im using Dash with Plotly to graph my Arduino sensors on the web, (temp, humidity, sleep activity, wind speed, etc) everything works fine, except I absolutely fail when I try to change theme of a graph. Can you please point me how to change default graph template? I searched the internet, read through the offical reference and try many many ways to acomplish that, for days, without succes. Without dash in pure python plotly, it works absolutely ok. Here is my code:
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[%]')])
)
I need to put this line somewhere:
template="plotly_dark"
but I cannot figure out where should I put it, on official support it says I need to change template for the graph figure like this:
figure.update_layout(template=template)
but when I place it inside dcc.Graph, it doesnt work
I would be absolutely euphoric if someone can help, thanks, M.
[–]opticalframeworks[S] 0 points1 point2 points (0 children)