JavaScript Figure Reference: indicator Traces
indicator trace is an object with the key "type" equal to "indicator" (i.e. {"type": "indicator"}) and any of the keys listed below. An indicator is used to visualize a single `value` along with some contextual information such as `steps` or a `threshold`, using a combination of three visual elements: a number, a delta, and/or a gauge. Deltas are taken with respect to a `reference`. Gauges can be either angular or bullet (aka linear) gauges.
- type
Parent:data[type=indicator]
Type: "indicator" - name
Parent:data[type=indicator]
Type: stringSets the trace name. The trace name appears as the legend item and on hover.
- title
Parent:data[type=indicator]
Type: object containing one or more of the keys listed below.- align
Parent:data[type=indicator].title
Type: enumerated , one of ("left"|"center"|"right")Sets the horizontal alignment of the title. It defaults to `center` except for bullet charts for which it defaults to right.
- font
Parent:data[type=indicator].title
Type: object containing one or more of the keys listed below.Set the font used to display the title
- color
Parent:data[type=indicator].title.font
Type: color - family
Parent:data[type=indicator].title.font
Type: stringHTML font family - the typeface that will be applied by the web browser. The web browser can only apply a font if it is available on the system where it runs. Provide multiple font families, separated by commas, to indicate the order in which to apply fonts if they aren't available.
- lineposition
Parent:data[type=indicator].title.font
Type: flaglist string. Any combination of"under","over","through"joined with a"+"OR"none".
Examples:"under","over","under+over","under+over+through","none"
Default:"none"Sets the kind of decoration line(s) with text, such as an "under", "over" or "through" as well as combinations e.g. "under+over", etc.
- shadow
Parent:data[type=indicator].title.font
Type: string
Default:"none"Sets the shape and color of the shadow behind text. "auto" places minimal shadow and applies contrast text font color. See https://developer.mozilla.org/en-US/docs/Web/CSS/text-shadow for additional options.
- size
Parent:data[type=indicator].title.font
Type: number greater than or equal to 1 - style
Parent:data[type=indicator].title.font
Type: enumerated , one of ("normal"|"italic")
Default:"normal"Sets whether a font should be styled with a normal or italic face from its family.
- textcase
Parent:data[type=indicator].title.font
Type: enumerated , one of ("normal"|"word caps"|"upper"|"lower")
Default:"normal"Sets capitalization of text. It can be used to make text appear in all-uppercase or all-lowercase, or with each word capitalized.
- variant
Parent:data[type=indicator].title.font
Type: enumerated , one of ("normal"|"small-caps"|"all-small-caps"|"all-petite-caps"|"petite-caps"|"unicase")
Default:"normal"Sets the variant of the font.
- weight
Parent:data[type=indicator].title.font
Type: integer between or equal to 1 and 1000
Default:normalSets the weight (or boldness) of the font.
- color
- text
Parent:data[type=indicator].title
Type: stringSets the title of this indicator.
- align
- visible
Parent:data[type=indicator]
Type: enumerated , one of (true|false|"legendonly")
Default:trueDetermines whether or not this trace is visible. If "legendonly", the trace is not drawn, but can appear as a legend item (provided that the legend itself is visible).
- legend
Parent:data[type=indicator]
Type: subplotid
Default:legendSets the reference to a legend to show this trace in. References to these legends are "legend", "legend2", "legend3", etc. Settings for these legends are set in the layout, under `layout.legend`, `layout.legend2`, etc.
- legendrank
Parent:data[type=indicator]
Type: number
Default:1000Sets the legend rank for this trace. Items and groups with smaller ranks are presented on top/left side while with "reversed" `legend.traceorder` they are on bottom/right side. The default legendrank is 1000, so that you can use ranks less than 1000 to place certain items before all unranked items, and ranks greater than 1000 to go after all unranked items. When having unranked or equal rank items shapes would be displayed after traces i.e. according to their order in data and layout.
- legendgrouptitle
Parent:data[type=indicator]
Type: object containing one or more of the keys listed below.- font
Parent:data[type=indicator].legendgrouptitle
Type: object containing one or more of the keys listed below.Sets this legend group's title font.
- color
Parent:data[type=indicator].legendgrouptitle.font
Type: color - family
Parent:data[type=indicator].legendgrouptitle.font
Type: stringHTML font family - the typeface that will be applied by the web browser. The web browser can only apply a font if it is available on the system where it runs. Provide multiple font families, separated by commas, to indicate the order in which to apply fonts if they aren't available.
- lineposition
Parent:data[type=indicator].legendgrouptitle.font
Type: flaglist string. Any combination of"under","over","through"joined with a"+"OR"none".
Examples:"under","over","under+over","under+over+through","none"
Default:"none"Sets the kind of decoration line(s) with text, such as an "under", "over" or "through" as well as combinations e.g. "under+over", etc.
- shadow
Parent:data[type=indicator].legendgrouptitle.font
Type: string
Default:"none"Sets the shape and color of the shadow behind text. "auto" places minimal shadow and applies contrast text font color. See https://developer.mozilla.org/en-US/docs/Web/CSS/text-shadow for additional options.
- size
Parent:data[type=indicator].legendgrouptitle.font
Type: number greater than or equal to 1 - style
Parent:data[type=indicator].legendgrouptitle.font
Type: enumerated , one of ("normal"|"italic")
Default:"normal"Sets whether a font should be styled with a normal or italic face from its family.
- textcase
Parent:data[type=indicator].legendgrouptitle.font
Type: enumerated , one of ("normal"|"word caps"|"upper"|"lower")
Default:"normal"Sets capitalization of text. It can be used to make text appear in all-uppercase or all-lowercase, or with each word capitalized.
- variant
Parent:data[type=indicator].legendgrouptitle.font
Type: enumerated , one of ("normal"|"small-caps"|"all-small-caps"|"all-petite-caps"|"petite-caps"|"unicase")
Default:"normal"Sets the variant of the font.
- weight
Parent:data[type=indicator].legendgrouptitle.font
Type: integer between or equal to 1 and 1000
Default:normalSets the weight (or boldness) of the font.
- color
- text
Parent:data[type=indicator].legendgrouptitle
Type: string
Default:""Sets the title of the legend group.
- font
- legendwidth
Parent:data[type=indicator]
Type: number greater than or equal to 0Sets the width (in px or fraction) of the legend for this trace.
- mode
Parent:data[type=indicator]
Type: flaglist string. Any combination of"number","delta","gauge"joined with a"+"
Examples:"number","delta","number+delta","number+delta+gauge"
Default:"number"Determines how the value is displayed on the graph. `number` displays the value numerically in text. `delta` displays the difference to a reference value in text. Finally, `gauge` displays the value graphically on an axis.
- ids
Parent:data[type=indicator]
Type: data arrayAssigns id labels to each datum. These ids for object constancy of data points during animation. Should be an array of strings, not numbers or any other type.
- value
Parent:data[type=indicator]
Type: numberSets the number to be displayed.
- meta
Parent:data[type=indicator]
Type: number or categorical coordinate stringAssigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace `name`, graph, axis and colorbar `title.text`, annotation `text` `rangeselector`, `updatemenues` and `sliders` `label` text all support `meta`. To access the trace `meta` values in an attribute in the same trace, simply use `%{meta[i]}` where `i` is the index or key of the `meta` item in question. To access trace `meta` in layout attributes, use `%{data[n[.meta[i]}` where `i` is the index or key of the `meta` and `n` is the trace index.
- customdata
Parent:data[type=indicator]
Type: data arrayAssigns extra data each datum. This may be useful when listening to hover, click and selection events. Note that, "scatter" traces also appends customdata items in the markers DOM elements
- domain
Parent:data[type=indicator]
Type: object containing one or more of the keys listed below.- column
Parent:data[type=indicator].domain
Type: integer greater than or equal to 0
Default:0If there is a layout grid, use the domain for this column in the grid for this indicator trace.
- row
Parent:data[type=indicator].domain
Type: integer greater than or equal to 0
Default:0If there is a layout grid, use the domain for this row in the grid for this indicator trace.
- x
Parent:data[type=indicator].domain
Type: array
Default:[0, 1]Sets the horizontal domain of this indicator trace (in plot fraction).
- y
Parent:data[type=indicator].domain
Type: array
Default:[0, 1]Sets the vertical domain of this indicator trace (in plot fraction).
- column
- align
Parent:data[type=indicator]
Type: enumerated , one of ("left"|"center"|"right")Sets the horizontal alignment of the `text` within the box. Note that this attribute has no effect if an angular gauge is displayed: in this case, it is always centered
- delta
Parent:data[type=indicator]
Type: object containing one or more of the keys listed below.- decreasing
Parent:data[type=indicator].delta
Type: object containing one or more of the keys listed below. - font
Parent:data[type=indicator].delta
Type: object containing one or more of the keys listed below.Set the font used to display the delta
- color
Parent:data[type=indicator].delta.font
Type: color - family
Parent:data[type=indicator].delta.font
Type: stringHTML font family - the typeface that will be applied by the web browser. The web browser can only apply a font if it is available on the system where it runs. Provide multiple font families, separated by commas, to indicate the order in which to apply fonts if they aren't available.
- lineposition
Parent:data[type=indicator].delta.font
Type: flaglist string. Any combination of"under","over","through"joined with a"+"OR"none".
Examples:"under","over","under+over","under+over+through","none"
Default:"none"Sets the kind of decoration line(s) with text, such as an "under", "over" or "through" as well as combinations e.g. "under+over", etc.
- shadow
Parent:data[type=indicator].delta.font
Type: string
Default:"none"Sets the shape and color of the shadow behind text. "auto" places minimal shadow and applies contrast text font color. See https://developer.mozilla.org/en-US/docs/Web/CSS/text-shadow for additional options.
- size
Parent:data[type=indicator].delta.font
Type: number greater than or equal to 1 - style
Parent:data[type=indicator].delta.font
Type: enumerated , one of ("normal"|"italic")
Default:"normal"Sets whether a font should be styled with a normal or italic face from its family.
- textcase
Parent:data[type=indicator].delta.font
Type: enumerated , one of ("normal"|"word caps"|"upper"|"lower")
Default:"normal"Sets capitalization of text. It can be used to make text appear in all-uppercase or all-lowercase, or with each word capitalized.
- variant
Parent:data[type=indicator].delta.font
Type: enumerated , one of ("normal"|"small-caps"|"all-small-caps"|"all-petite-caps"|"petite-caps"|"unicase")
Default:"normal"Sets the variant of the font.
- weight
Parent:data[type=indicator].delta.font
Type: integer between or equal to 1 and 1000
Default:normalSets the weight (or boldness) of the font.
- color
- increasing
Parent:data[type=indicator].delta
Type: object containing one or more of the keys listed below. - position
Parent:data[type=indicator].delta
Type: enumerated , one of ("top"|"bottom"|"left"|"right")
Default:"bottom"Sets the position of delta with respect to the number.
- prefix
Parent:data[type=indicator].delta
Type: string
Default:""Sets a prefix appearing before the delta.
- reference
Parent:data[type=indicator].delta
Type: numberSets the reference value to compute the delta. By default, it is set to the current value.
- relative
- decreasing