How do i remove the needle in the dash-gauge ?
Hi @Durgesh and welcome to the Community.
I think you can’t remove the niddle of the Dash Gauge but you can build your custom graph Indicator like this:
Here is the link: Indicators | Python | Plotly
Thank you,
Could you please provide me the code for it.
In the link I provided you can find different examples and at the end a brief explanation how to do that with Dash.
I have no examples of go.Indicator but this is an example of a go.Waterfall graph figure in Dash that you must return to the Output(“your_graph_id”, “figure”):
fig_variable = {"data": [go.Waterfall(x = [desde, "Contr Marg", "SG&A costs", "R&D costs", "Sub-total", "Dep & Amort", "Non Op. Inc/Exp",
"Interest Exp", "Other Inc/Exp", "Income Tax", "Minority Interest", hasta],
y = [start, gross, sga, rd, None, dep, noie, intexp, oie, it, mi, None], base = 0,
measure = ["absolute", "relative", "relative", "relative", "total", "relative", "relative", "relative",
"relative", "relative", "relative", "total"],
textposition = "outside", texttemplate = "%{text:.0f}",
cliponaxis=False,
text = [start, gross, sga, rd, sub, dep, noie, intexp, oie, it, mi, end],
decreasing = {"marker":{"color":"OrangeRed"}}, increasing = {"marker":{"color":"LimeGreen"}},
hoverinfo = "initial+y", totals = {"marker":{"color":"blue", "line":{"color":'blue', "width":3}}})],
"layout": go.Layout(title = "Net Income differences from "+desde+" to "+hasta, waterfallgap = 0.3,
autosize= True, height=280,
margin={"r": 60, "t": 45, "b": 70, "l": 45})}
return fig_variable
You need to build your figure in a variable using: your_variable= {“data”: [go.Indicator( and the apropiate properties of your indicator.
And a “layout”: go.Layout( with the title and other layout options as explained in the documentation.
And then return the variable to the output figure.