Plotly go.Indicator shows only empty chart

Hi,

I have an issue with go.Indicator chart type in Jupyter notebook.
I am using plotly 4.6.0.
It seems like the Indicator chart type is no more supporte, because whatever data, properties I set I only get the empty chart

import plotly.graph_objects as go

fig = go.Figure(go.Indicator(
mode = “number+gauge+delta”,
gauge = {‘shape’: “bullet”},
delta = {‘reference’: 300},
value = 220,
domain = {‘x’: [0.1, 1], ‘y’: [0.2, 0.9]},
title = {‘text’: “Avg order size”}))

fig.show()

Any idea what is the issue?

Hi, and welcome to the forum!

I think your issue might have to do with the characters you are using to delinate strings in your code. Notice the difference between " and , and also between ' and !

Try:

import plotly.graph_objects as go

fig = go.Figure(go.Indicator(mode = "number+gauge+delta", gauge = {'shape': 'bullet'},
    delta = {'reference': 300}, value = 220, domain = {'x': [0.1, 1], 'y': [0.2, 0.9]}, 
    title = {'text': 'Avg order size'}))

fig.show()

hm…I have no clue why those strange characters appeared, since I have just copied an example from

however it does not matter in my notebook, whatever I plot I got the same empty chart…this is really strange
Even in a new notebook I try only simple number indicator

Could it be caused by some other environment libraries or other dependencies?

Can you please check which version of plotly.py you are running in your notebook? The following code should do it.

import plotly
plotly.__version__

Also, it would be useful to know which renderer is active in your notebook:

import plotly.io as pio
pio.renderers

And also, are you able to create and display other types of figures, such as a bar or a pie chart? Or does this issue only occur with Indicator figures?

sure

Other types of figures displays fine, the issue is only with Indicator figures.
thanks