plotly.graph_objects packageΒΆ
-
class
plotly.graph_objects.AngularAxis(*args, **kwargs)ΒΆ Bases:
dictplotly.graph_objects.AngularAxis is deprecated.
- Please replace it with one of the following more specific types
plotly.graph_objects.layout.AngularAxis
plotly.graph_objects.layout.polar.AngularAxis
-
class
plotly.graph_objects.Annotation(*args, **kwargs)ΒΆ Bases:
dictplotly.graph_objects.Annotation is deprecated.
- Please replace it with one of the following more specific types
plotly.graph_objects.layout.Annotation
plotly.graph_objects.layout.scene.Annotation
-
class
plotly.graph_objects.Annotations(*args, **kwargs)ΒΆ Bases:
listplotly.graph_objects.Annotations is deprecated.
- Please replace it with a list or tuple of instances of the following types
plotly.graph_objects.layout.Annotation
plotly.graph_objects.layout.scene.Annotation
-
class
plotly.graph_objects.Area(arg=None, customdata=None, customdatasrc=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, ids=None, idssrc=None, legendgroup=None, marker=None, meta=None, metasrc=None, name=None, opacity=None, r=None, rsrc=None, showlegend=None, stream=None, t=None, tsrc=None, uid=None, uirevision=None, visible=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βxβ, βyβ, βzβ, βtextβ, βnameβ] joined with β+β characters (e.g. βx+yβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.area.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
markerΒΆ The βmarkerβ property is an instance of Marker that may be specified as:
An instance of
plotly.graph_objects.area.MarkerA dict of string/value properties that will be passed to the Marker constructor
Supported dict properties:
- color
Area traces are deprecated! Please switch to the βbarpolarβ trace type. Sets themarkercolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to
marker.cminandmarker.cmaxif set.- colorsrc
Sets the source reference on Chart Studio Cloud for color .
- opacity
Area traces are deprecated! Please switch to the βbarpolarβ trace type. Sets the marker opacity.
- opacitysrc
Sets the source reference on Chart Studio Cloud for opacity .
- size
Area traces are deprecated! Please switch to the βbarpolarβ trace type. Sets the marker size (in px).
- sizesrc
Sets the source reference on Chart Studio Cloud for size .
- symbol
Area traces are deprecated! Please switch to the βbarpolarβ trace type. Sets the marker symbol type. Adding 100 is equivalent to appending β-openβ to a symbol name. Adding 200 is equivalent to appending β-dotβ to a symbol name. Adding 300 is equivalent to appending β-open-dotβ or βdot-openβ to a symbol name.
- symbolsrc
Sets the source reference on Chart Studio Cloud for symbol .
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the trace.
- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
rΒΆ Area traces are deprecated! Please switch to the βbarpolarβ trace type. Sets the radial coordinates for legacy polar chart only.
The βrβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
rsrcΒΆ Sets the source reference on Chart Studio Cloud for r .
The βrsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.area.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
tΒΆ Area traces are deprecated! Please switch to the βbarpolarβ trace type. Sets the angular coordinates for legacy polar chart only.
The βtβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
tsrcΒΆ Sets the source reference on Chart Studio Cloud for t .
The βtsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
-
class
plotly.graph_objects.Bar(arg=None, alignmentgroup=None, base=None, basesrc=None, cliponaxis=None, constraintext=None, customdata=None, customdatasrc=None, dx=None, dy=None, error_x=None, error_y=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, insidetextanchor=None, insidetextfont=None, legendgroup=None, marker=None, meta=None, metasrc=None, name=None, offset=None, offsetgroup=None, offsetsrc=None, opacity=None, orientation=None, outsidetextfont=None, r=None, rsrc=None, selected=None, selectedpoints=None, showlegend=None, stream=None, t=None, text=None, textangle=None, textfont=None, textposition=None, textpositionsrc=None, textsrc=None, texttemplate=None, texttemplatesrc=None, tsrc=None, uid=None, uirevision=None, unselected=None, visible=None, width=None, widthsrc=None, x=None, x0=None, xaxis=None, xcalendar=None, xsrc=None, y=None, y0=None, yaxis=None, ycalendar=None, ysrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
alignmentgroupΒΆ Set several traces linked to the same position axis or matching axes to the same alignmentgroup. This controls whether bars compute their positional range dependently or independently.
- The βalignmentgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
baseΒΆ Sets where the bar base is drawn (in position axis units). In βstackβ or βrelativeβ barmode, traces that set βbaseβ will be excluded and drawn in βoverlayβ mode instead.
The βbaseβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
basesrcΒΆ Sets the source reference on Chart Studio Cloud for base .
The βbasesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
cliponaxisΒΆ Determines whether the text nodes are clipped about the subplot axes. To show the text nodes above axis lines and tick labels, make sure to set
xaxis.layerandyaxis.layerto below traces.The βcliponaxisβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
constraintextΒΆ Constrain the size of text inside or outside a bar to be no larger than the bar itself.
- The βconstraintextβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βinsideβ, βoutsideβ, βbothβ, βnoneβ]
- Returns
- Return type
Any
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
dxΒΆ Sets the x coordinate step. See
x0for more info.- The βdxβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
dyΒΆ Sets the y coordinate step. See
y0for more info.- The βdyβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
error_xΒΆ The βerror_xβ property is an instance of ErrorX that may be specified as:
An instance of
plotly.graph_objects.bar.ErrorXA dict of string/value properties that will be passed to the ErrorX constructor
Supported dict properties:
- array
Sets the data corresponding the length of each error bar. Values are plotted relative to the underlying data.
- arrayminus
Sets the data corresponding the length of each error bar in the bottom (left) direction for vertical (horizontal) bars Values are plotted relative to the underlying data.
- arrayminussrc
Sets the source reference on Chart Studio Cloud for arrayminus .
- arraysrc
Sets the source reference on Chart Studio Cloud for array .
- color
Sets the stoke color of the error bars.
copy_ystyle
- symmetric
Determines whether or not the error bars have the same length in both direction (top/bottom for vertical bars, left/right for horizontal bars.
- thickness
Sets the thickness (in px) of the error bars.
traceref
tracerefminus
- type
Determines the rule used to generate the error bars. If *constant`, the bar lengths are of a constant value. Set this constant in
value. If βpercentβ, the bar lengths correspond to a percentage of underlying data. Set this percentage invalue. If βsqrtβ, the bar lengths correspond to the sqaure of the underlying data. If βdataβ, the bar lengths are set with data setarray.- value
Sets the value of either the percentage (if
typeis set to βpercentβ) or the constant (iftypeis set to βconstantβ) corresponding to the lengths of the error bars.- valueminus
Sets the value of either the percentage (if
typeis set to βpercentβ) or the constant (iftypeis set to βconstantβ) corresponding to the lengths of the error bars in the bottom (left) direction for vertical (horizontal) bars- visible
Determines whether or not this set of error bars is visible.
- width
Sets the width (in px) of the cross-bar at both ends of the error bars.
- Returns
- Return type
-
property
error_yΒΆ The βerror_yβ property is an instance of ErrorY that may be specified as:
An instance of
plotly.graph_objects.bar.ErrorYA dict of string/value properties that will be passed to the ErrorY constructor
Supported dict properties:
- array
Sets the data corresponding the length of each error bar. Values are plotted relative to the underlying data.
- arrayminus
Sets the data corresponding the length of each error bar in the bottom (left) direction for vertical (horizontal) bars Values are plotted relative to the underlying data.
- arrayminussrc
Sets the source reference on Chart Studio Cloud for arrayminus .
- arraysrc
Sets the source reference on Chart Studio Cloud for array .
- color
Sets the stoke color of the error bars.
- symmetric
Determines whether or not the error bars have the same length in both direction (top/bottom for vertical bars, left/right for horizontal bars.
- thickness
Sets the thickness (in px) of the error bars.
traceref
tracerefminus
- type
Determines the rule used to generate the error bars. If *constant`, the bar lengths are of a constant value. Set this constant in
value. If βpercentβ, the bar lengths correspond to a percentage of underlying data. Set this percentage invalue. If βsqrtβ, the bar lengths correspond to the sqaure of the underlying data. If βdataβ, the bar lengths are set with data setarray.- value
Sets the value of either the percentage (if
typeis set to βpercentβ) or the constant (iftypeis set to βconstantβ) corresponding to the lengths of the error bars.- valueminus
Sets the value of either the percentage (if
typeis set to βpercentβ) or the constant (iftypeis set to βconstantβ) corresponding to the lengths of the error bars in the bottom (left) direction for vertical (horizontal) bars- visible
Determines whether or not this set of error bars is visible.
- width
Sets the width (in px) of the cross-bar at both ends of the error bars.
- Returns
- Return type
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βxβ, βyβ, βzβ, βtextβ, βnameβ] joined with β+β characters (e.g. βx+yβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.bar.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- Returns
- Return type
-
property
hovertemplateΒΆ Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time- formatβs syntax %{variable|d3-time-format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time- format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. variablesvalueandlabel. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.- The βhovertemplateβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertemplatesrcΒΆ Sets the source reference on Chart Studio Cloud for hovertemplate .
The βhovertemplatesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hovertextΒΆ Sets hover text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this traceβs (x,y) coordinates. To be seen, trace
hoverinfomust contain a βtextβ flag.- The βhovertextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
insidetextanchorΒΆ Determines if texts are kept at center or start/end points in
textpositionβinsideβ mode.- The βinsidetextanchorβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βendβ, βmiddleβ, βstartβ]
- Returns
- Return type
Any
-
property
insidetextfontΒΆ Sets the font used for
textlying inside the bar.The βinsidetextfontβ property is an instance of Insidetextfont that may be specified as:
An instance of
plotly.graph_objects.bar.InsidetextfontA dict of string/value properties that will be passed to the Insidetextfont constructor
Supported dict properties:
color
- colorsrc
Sets the source reference on Chart Studio Cloud for color .
- family
HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they arenβt available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include βArialβ, βBaltoβ, βCourier Newβ, βDroid Sansβ,, βDroid Serifβ, βDroid Sans Monoβ, βGravitas Oneβ, βOld Standard TTβ, βOpen Sansβ, βOverpassβ, βPT Sans Narrowβ, βRalewayβ, βTimes New Romanβ.
- familysrc
Sets the source reference on Chart Studio Cloud for family .
size
- sizesrc
Sets the source reference on Chart Studio Cloud for size .
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
markerΒΆ The βmarkerβ property is an instance of Marker that may be specified as:
An instance of
plotly.graph_objects.bar.MarkerA dict of string/value properties that will be passed to the Marker constructor
Supported dict properties:
- autocolorscale
Determines whether the colorscale is a default palette (
autocolorscale: true) or the palette determined bymarker.colorscale. Has an effect only if inmarker.color`is set to a numerical array. In case `colorscaleis unspecified orautocolorscaleis true, the default palette will be chosen according to whether numbers in thecolorarray are all positive, all negative or mixed.- cauto
Determines whether or not the color domain is computed with respect to the input data (here in
marker.color) or the bounds set inmarker.cminandmarker.cmaxHas an effect only if inmarker.color`is set to a numerical array. Defaults to `falsewhenmarker.cminandmarker.cmaxare set by the user.- cmax
Sets the upper bound of the color domain. Has an effect only if in
marker.color`is set to a numerical array. Value should have the same units as in `marker.colorand if set,marker.cminmust be set as well.- cmid
Sets the mid-point of the color domain by scaling
marker.cminand/ormarker.cmaxto be equidistant to this point. Has an effect only if inmarker.color`is set to a numerical array. Value should have the same units as in `marker.color. Has no effect whenmarker.cautoisfalse.- cmin
Sets the lower bound of the color domain. Has an effect only if in
marker.color`is set to a numerical array. Value should have the same units as in `marker.colorand if set,marker.cmaxmust be set as well.- color
Sets themarkercolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to
marker.cminandmarker.cmaxif set.- coloraxis
Sets a reference to a shared color axis. References to these shared color axes are βcoloraxisβ, βcoloraxis2β, βcoloraxis3β, etc. Settings for these shared color axes are set in the layout, under
layout.coloraxis,layout.coloraxis2, etc. Note that multiple color scales can be linked to the same color axis.- colorbar
plotly.graph_objects.bar.marker.ColorBa rinstance or dict with compatible properties- colorscale
Sets the colorscale. Has an effect only if in
marker.color`is set to a numerical array. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example, `[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]. To control the bounds of the colorscale in color space, use`marker.cmin` andmarker.cmax. Alternatively,colorscalemay be a palette name string of the following list: Greys,YlGnBu,Greens,YlOrRd,Bluered,RdBu,Reds,Bl ues,Picnic,Rainbow,Portland,Jet,Hot,Blackbody,E arth,Electric,Viridis,Cividis.- colorsrc
Sets the source reference on Chart Studio Cloud for color .
- line
plotly.graph_objects.bar.marker.Lineinstance or dict with compatible properties- opacity
Sets the opacity of the bars.
- opacitysrc
Sets the source reference on Chart Studio Cloud for opacity .
- reversescale
Reverses the color mapping if true. Has an effect only if in
marker.color`is set to a numerical array. If true, `marker.cminwill correspond to the last color in the array andmarker.cmaxwill correspond to the first color.- showscale
Determines whether or not a colorbar is displayed for this trace. Has an effect only if in `marker.color`is set to a numerical array.
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
offsetΒΆ Shifts the position where the bar is drawn (in position axis units). In βgroupβ barmode, traces that set βoffsetβ will be excluded and drawn in βoverlayβ mode instead.
- The βoffsetβ property is a number and may be specified as:
An int or float
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
int|float|numpy.ndarray
-
property
offsetgroupΒΆ Set several traces linked to the same position axis or matching axes to the same offsetgroup where bars of the same position coordinate will line up.
- The βoffsetgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
offsetsrcΒΆ Sets the source reference on Chart Studio Cloud for offset .
The βoffsetsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the trace.
- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
orientationΒΆ Sets the orientation of the bars. With βvβ (βhβ), the value of the each bar spans along the vertical (horizontal).
- The βorientationβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βvβ, βhβ]
- Returns
- Return type
Any
-
property
outsidetextfontΒΆ Sets the font used for
textlying outside the bar.The βoutsidetextfontβ property is an instance of Outsidetextfont that may be specified as:
An instance of
plotly.graph_objects.bar.OutsidetextfontA dict of string/value properties that will be passed to the Outsidetextfont constructor
Supported dict properties:
color
- colorsrc
Sets the source reference on Chart Studio Cloud for color .
- family
HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they arenβt available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include βArialβ, βBaltoβ, βCourier Newβ, βDroid Sansβ,, βDroid Serifβ, βDroid Sans Monoβ, βGravitas Oneβ, βOld Standard TTβ, βOpen Sansβ, βOverpassβ, βPT Sans Narrowβ, βRalewayβ, βTimes New Romanβ.
- familysrc
Sets the source reference on Chart Studio Cloud for family .
size
- sizesrc
Sets the source reference on Chart Studio Cloud for size .
- Returns
- Return type
-
property
rΒΆ r coordinates in scatter traces are deprecated!Please switch to the βscatterpolarβ trace type.Sets the radial coordinatesfor legacy polar chart only.
The βrβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
rsrcΒΆ Sets the source reference on Chart Studio Cloud for r .
The βrsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
selectedΒΆ The βselectedβ property is an instance of Selected that may be specified as:
An instance of
plotly.graph_objects.bar.SelectedA dict of string/value properties that will be passed to the Selected constructor
Supported dict properties:
- marker
plotly.graph_objects.bar.selected.Marke rinstance or dict with compatible properties- textfont
plotly.graph_objects.bar.selected.Textf ontinstance or dict with compatible properties
- Returns
- Return type
-
property
selectedpointsΒΆ Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.The βselectedpointsβ property accepts values of any type
- Returns
- Return type
Any
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.bar.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
tΒΆ t coordinates in scatter traces are deprecated!Please switch to the βscatterpolarβ trace type.Sets the angular coordinatesfor legacy polar chart only.
The βtβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
textΒΆ Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this traceβs (x,y) coordinates. If trace
hoverinfocontains a βtextβ flag and βhovertextβ is not set, these elements will be seen in the hover labels.- The βtextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
textangleΒΆ Sets the angle of the tick labels with respect to the bar. For example, a
tickangleof -90 draws the tick labels vertically. With βautoβ the texts may automatically be rotated to fit with the maximum size in bars.The βtextangleβ property is a angle (in degrees) that may be specified as a number between -180 and 180. Numeric values outside this range are converted to the equivalent value (e.g. 270 is converted to -90).
- Returns
- Return type
int|float
-
property
textfontΒΆ Sets the font used for
text.The βtextfontβ property is an instance of Textfont that may be specified as:
An instance of
plotly.graph_objects.bar.TextfontA dict of string/value properties that will be passed to the Textfont constructor
Supported dict properties:
color
- colorsrc
Sets the source reference on Chart Studio Cloud for color .
- family
HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they arenβt available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include βArialβ, βBaltoβ, βCourier Newβ, βDroid Sansβ,, βDroid Serifβ, βDroid Sans Monoβ, βGravitas Oneβ, βOld Standard TTβ, βOpen Sansβ, βOverpassβ, βPT Sans Narrowβ, βRalewayβ, βTimes New Romanβ.
- familysrc
Sets the source reference on Chart Studio Cloud for family .
size
- sizesrc
Sets the source reference on Chart Studio Cloud for size .
- Returns
- Return type
-
property
textpositionΒΆ Specifies the location of the
text. βinsideβ positionstextinside, next to the bar end (rotated and scaled if needed). βoutsideβ positionstextoutside, next to the bar end (scaled if needed), unless there is another bar stacked on this one, then the text gets pushed inside. βautoβ tries to positiontextinside the bar, but if the bar is too small and no bar is stacked on this one the text is moved outside.- The βtextpositionβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βinsideβ, βoutsideβ, βautoβ, βnoneβ]
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
textpositionsrcΒΆ Sets the source reference on Chart Studio Cloud for textposition .
The βtextpositionsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
texttemplateΒΆ Template string used for rendering the information text that appear on points. Note that this will override
textinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time- formatβs syntax %{variable|d3-time-format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time- format#locale_format for details on the date formatting syntax. Every attributes that can be specified per-point (the ones that arearrayOk: true) are available. variablesvalueandlabel.- The βtexttemplateβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
texttemplatesrcΒΆ Sets the source reference on Chart Studio Cloud for texttemplate .
The βtexttemplatesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
tsrcΒΆ Sets the source reference on Chart Studio Cloud for t .
The βtsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
unselectedΒΆ The βunselectedβ property is an instance of Unselected that may be specified as:
An instance of
plotly.graph_objects.bar.UnselectedA dict of string/value properties that will be passed to the Unselected constructor
Supported dict properties:
- marker
plotly.graph_objects.bar.unselected.Mar kerinstance or dict with compatible properties- textfont
plotly.graph_objects.bar.unselected.Tex tfontinstance or dict with compatible properties
- Returns
- Return type
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
widthΒΆ Sets the bar width (in position axis units).
- The βwidthβ property is a number and may be specified as:
An int or float in the interval [0, inf]
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
int|float|numpy.ndarray
-
property
widthsrcΒΆ Sets the source reference on Chart Studio Cloud for width .
The βwidthsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
xΒΆ Sets the x coordinates.
The βxβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
x0ΒΆ Alternate to
x. Builds a linear space of x coordinates. Use withdxwherex0is the starting coordinate anddxthe step.The βx0β property accepts values of any type
- Returns
- Return type
Any
-
property
xaxisΒΆ Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.The βxaxisβ property is an identifier of a particular subplot, of type βxβ, that may be specified as the string βxβ optionally followed by an integer >= 1 (e.g. βxβ, βx1β, βx2β, βx3β, etc.)
- Returns
- Return type
-
property
xcalendarΒΆ Sets the calendar system to use with
xdate data.- The βxcalendarβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βgregorianβ, βchineseβ, βcopticβ, βdiscworldβ, βethiopianβ, βhebrewβ, βislamicβ, βjulianβ, βmayanβ, βnanakshahiβ, βnepaliβ, βpersianβ, βjalaliβ, βtaiwanβ, βthaiβ, βummalquraβ]
- Returns
- Return type
Any
-
property
xsrcΒΆ Sets the source reference on Chart Studio Cloud for x .
The βxsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
yΒΆ Sets the y coordinates.
The βyβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
y0ΒΆ Alternate to
y. Builds a linear space of y coordinates. Use withdywherey0is the starting coordinate anddythe step.The βy0β property accepts values of any type
- Returns
- Return type
Any
-
property
yaxisΒΆ Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.The βyaxisβ property is an identifier of a particular subplot, of type βyβ, that may be specified as the string βyβ optionally followed by an integer >= 1 (e.g. βyβ, βy1β, βy2β, βy3β, etc.)
- Returns
- Return type
-
property
ycalendarΒΆ Sets the calendar system to use with
ydate data.- The βycalendarβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βgregorianβ, βchineseβ, βcopticβ, βdiscworldβ, βethiopianβ, βhebrewβ, βislamicβ, βjulianβ, βmayanβ, βnanakshahiβ, βnepaliβ, βpersianβ, βjalaliβ, βtaiwanβ, βthaiβ, βummalquraβ]
- Returns
- Return type
Any
-
property
-
class
plotly.graph_objects.Barpolar(arg=None, base=None, basesrc=None, customdata=None, customdatasrc=None, dr=None, dtheta=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, legendgroup=None, marker=None, meta=None, metasrc=None, name=None, offset=None, offsetsrc=None, opacity=None, r=None, r0=None, rsrc=None, selected=None, selectedpoints=None, showlegend=None, stream=None, subplot=None, text=None, textsrc=None, theta=None, theta0=None, thetasrc=None, thetaunit=None, uid=None, uirevision=None, unselected=None, visible=None, width=None, widthsrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
baseΒΆ Sets where the bar base is drawn (in radial axis units). In βstackβ barmode, traces that set βbaseβ will be excluded and drawn in βoverlayβ mode instead.
The βbaseβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
basesrcΒΆ Sets the source reference on Chart Studio Cloud for base .
The βbasesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
drΒΆ Sets the r coordinate step.
- The βdrβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
dthetaΒΆ Sets the theta coordinate step. By default, the
dthetastep equals the subplotβs period divided by the length of thercoordinates.- The βdthetaβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βrβ, βthetaβ, βtextβ, βnameβ] joined with β+β characters (e.g. βr+thetaβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.barpolar.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- Returns
- Return type
-
property
hovertemplateΒΆ Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time- formatβs syntax %{variable|d3-time-format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time- format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.- The βhovertemplateβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertemplatesrcΒΆ Sets the source reference on Chart Studio Cloud for hovertemplate .
The βhovertemplatesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hovertextΒΆ Same as
text.- The βhovertextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
markerΒΆ The βmarkerβ property is an instance of Marker that may be specified as:
An instance of
plotly.graph_objects.barpolar.MarkerA dict of string/value properties that will be passed to the Marker constructor
Supported dict properties:
- autocolorscale
Determines whether the colorscale is a default palette (
autocolorscale: true) or the palette determined bymarker.colorscale. Has an effect only if inmarker.color`is set to a numerical array. In case `colorscaleis unspecified orautocolorscaleis true, the default palette will be chosen according to whether numbers in thecolorarray are all positive, all negative or mixed.- cauto
Determines whether or not the color domain is computed with respect to the input data (here in
marker.color) or the bounds set inmarker.cminandmarker.cmaxHas an effect only if inmarker.color`is set to a numerical array. Defaults to `falsewhenmarker.cminandmarker.cmaxare set by the user.- cmax
Sets the upper bound of the color domain. Has an effect only if in
marker.color`is set to a numerical array. Value should have the same units as in `marker.colorand if set,marker.cminmust be set as well.- cmid
Sets the mid-point of the color domain by scaling
marker.cminand/ormarker.cmaxto be equidistant to this point. Has an effect only if inmarker.color`is set to a numerical array. Value should have the same units as in `marker.color. Has no effect whenmarker.cautoisfalse.- cmin
Sets the lower bound of the color domain. Has an effect only if in
marker.color`is set to a numerical array. Value should have the same units as in `marker.colorand if set,marker.cmaxmust be set as well.- color
Sets themarkercolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to
marker.cminandmarker.cmaxif set.- coloraxis
Sets a reference to a shared color axis. References to these shared color axes are βcoloraxisβ, βcoloraxis2β, βcoloraxis3β, etc. Settings for these shared color axes are set in the layout, under
layout.coloraxis,layout.coloraxis2, etc. Note that multiple color scales can be linked to the same color axis.- colorbar
plotly.graph_objects.barpolar.marker.Co lorBarinstance or dict with compatible properties- colorscale
Sets the colorscale. Has an effect only if in
marker.color`is set to a numerical array. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example, `[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]. To control the bounds of the colorscale in color space, use`marker.cmin` andmarker.cmax. Alternatively,colorscalemay be a palette name string of the following list: Greys,YlGnBu,Greens,YlOrRd,Bluered,RdBu,Reds,Bl ues,Picnic,Rainbow,Portland,Jet,Hot,Blackbody,E arth,Electric,Viridis,Cividis.- colorsrc
Sets the source reference on Chart Studio Cloud for color .
- line
plotly.graph_objects.barpolar.marker.Li neinstance or dict with compatible properties- opacity
Sets the opacity of the bars.
- opacitysrc
Sets the source reference on Chart Studio Cloud for opacity .
- reversescale
Reverses the color mapping if true. Has an effect only if in
marker.color`is set to a numerical array. If true, `marker.cminwill correspond to the last color in the array andmarker.cmaxwill correspond to the first color.- showscale
Determines whether or not a colorbar is displayed for this trace. Has an effect only if in `marker.color`is set to a numerical array.
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
offsetΒΆ Shifts the angular position where the bar is drawn (in βthetatunitβ units).
- The βoffsetβ property is a number and may be specified as:
An int or float
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
int|float|numpy.ndarray
-
property
offsetsrcΒΆ Sets the source reference on Chart Studio Cloud for offset .
The βoffsetsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the trace.
- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
rΒΆ Sets the radial coordinates
The βrβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
r0ΒΆ Alternate to
r. Builds a linear space of r coordinates. Use withdrwherer0is the starting coordinate anddrthe step.The βr0β property accepts values of any type
- Returns
- Return type
Any
-
property
rsrcΒΆ Sets the source reference on Chart Studio Cloud for r .
The βrsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
selectedΒΆ The βselectedβ property is an instance of Selected that may be specified as:
An instance of
plotly.graph_objects.barpolar.SelectedA dict of string/value properties that will be passed to the Selected constructor
Supported dict properties:
- marker
plotly.graph_objects.barpolar.selected. Markerinstance or dict with compatible properties- textfont
plotly.graph_objects.barpolar.selected. Textfontinstance or dict with compatible properties
- Returns
- Return type
-
property
selectedpointsΒΆ Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.The βselectedpointsβ property accepts values of any type
- Returns
- Return type
Any
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.barpolar.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
subplotΒΆ Sets a reference between this traceβs data coordinates and a polar subplot. If βpolarβ (the default value), the data refer to
layout.polar. If βpolar2β, the data refer tolayout.polar2, and so on.The βsubplotβ property is an identifier of a particular subplot, of type βpolarβ, that may be specified as the string βpolarβ optionally followed by an integer >= 1 (e.g. βpolarβ, βpolar1β, βpolar2β, βpolar3β, etc.)
- Returns
- Return type
-
property
textΒΆ Sets hover text elements associated with each bar. If a single string, the same string appears over all bars. If an array of string, the items are mapped in order to the this traceβs coordinates.
- The βtextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
thetaΒΆ Sets the angular coordinates
The βthetaβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
theta0ΒΆ Alternate to
theta. Builds a linear space of theta coordinates. Use withdthetawheretheta0is the starting coordinate anddthetathe step.The βtheta0β property accepts values of any type
- Returns
- Return type
Any
-
property
thetasrcΒΆ Sets the source reference on Chart Studio Cloud for theta .
The βthetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
thetaunitΒΆ Sets the unit of input βthetaβ values. Has an effect only when on βlinearβ angular axes.
- The βthetaunitβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βradiansβ, βdegreesβ, βgradiansβ]
- Returns
- Return type
Any
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
unselectedΒΆ The βunselectedβ property is an instance of Unselected that may be specified as:
An instance of
plotly.graph_objects.barpolar.UnselectedA dict of string/value properties that will be passed to the Unselected constructor
Supported dict properties:
- marker
plotly.graph_objects.barpolar.unselecte d.Markerinstance or dict with compatible properties- textfont
plotly.graph_objects.barpolar.unselecte d.Textfontinstance or dict with compatible properties
- Returns
- Return type
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
widthΒΆ Sets the bar angular width (in βthetaunitβ units).
- The βwidthβ property is a number and may be specified as:
An int or float in the interval [0, inf]
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
int|float|numpy.ndarray
-
property
-
class
plotly.graph_objects.Box(arg=None, alignmentgroup=None, boxmean=None, boxpoints=None, customdata=None, customdatasrc=None, dx=None, dy=None, fillcolor=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hoveron=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, jitter=None, legendgroup=None, line=None, lowerfence=None, lowerfencesrc=None, marker=None, mean=None, meansrc=None, median=None, mediansrc=None, meta=None, metasrc=None, name=None, notched=None, notchspan=None, notchspansrc=None, notchwidth=None, offsetgroup=None, opacity=None, orientation=None, pointpos=None, q1=None, q1src=None, q3=None, q3src=None, quartilemethod=None, sd=None, sdsrc=None, selected=None, selectedpoints=None, showlegend=None, stream=None, text=None, textsrc=None, uid=None, uirevision=None, unselected=None, upperfence=None, upperfencesrc=None, visible=None, whiskerwidth=None, width=None, x=None, x0=None, xaxis=None, xcalendar=None, xsrc=None, y=None, y0=None, yaxis=None, ycalendar=None, ysrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
alignmentgroupΒΆ Set several traces linked to the same position axis or matching axes to the same alignmentgroup. This controls whether bars compute their positional range dependently or independently.
- The βalignmentgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
boxmeanΒΆ If True, the mean of the box(es)β underlying distribution is drawn as a dashed line inside the box(es). If βsdβ the standard deviation is also drawn. Defaults to True when
meanis set. Defaults to βsdβ whensdis set Otherwise defaults to False.- The βboxmeanβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, βsdβ, False]
- Returns
- Return type
Any
-
property
boxpointsΒΆ If βoutliersβ, only the sample points lying outside the whiskers are shown If βsuspectedoutliersβ, the outlier points are shown and points either less than 4*Q1-3*Q3 or greater than 4*Q3-3*Q1 are highlighted (see
outliercolor) If βallβ, all sample points are shown If False, only the box(es) are shown with no sample points Defaults to βsuspectedoutliersβ whenmarker.outliercolorormarker.line.outliercoloris set. Defaults to βallβ under the q1/median/q3 signature. Otherwise defaults to βoutliersβ.- The βboxpointsβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βallβ, βoutliersβ, βsuspectedoutliersβ, False]
- Returns
- Return type
Any
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
dxΒΆ Sets the x coordinate step for multi-box traces set using q1/median/q3.
- The βdxβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
dyΒΆ Sets the y coordinate step for multi-box traces set using q1/median/q3.
- The βdyβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
fillcolorΒΆ Sets the fill color. Defaults to a half-transparent variant of the line color, marker color, or marker line color, whichever is available.
- The βfillcolorβ property is a color and may be specified as:
A hex string (e.g. β#ff0000β)
An rgb/rgba string (e.g. βrgb(255,0,0)β)
An hsl/hsla string (e.g. βhsl(0,100%,50%)β)
An hsv/hsva string (e.g. βhsv(0,100%,100%)β)
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure, beige, bisque, black, blanchedalmond, blue, blueviolet, brown, burlywood, cadetblue, chartreuse, chocolate, coral, cornflowerblue, cornsilk, crimson, cyan, darkblue, darkcyan, darkgoldenrod, darkgray, darkgrey, darkgreen, darkkhaki, darkmagenta, darkolivegreen, darkorange, darkorchid, darkred, darksalmon, darkseagreen, darkslateblue, darkslategray, darkslategrey, darkturquoise, darkviolet, deeppink, deepskyblue, dimgray, dimgrey, dodgerblue, firebrick, floralwhite, forestgreen, fuchsia, gainsboro, ghostwhite, gold, goldenrod, gray, grey, green, greenyellow, honeydew, hotpink, indianred, indigo, ivory, khaki, lavender, lavenderblush, lawngreen, lemonchiffon, lightblue, lightcoral, lightcyan, lightgoldenrodyellow, lightgray, lightgrey, lightgreen, lightpink, lightsalmon, lightseagreen, lightskyblue, lightslategray, lightslategrey, lightsteelblue, lightyellow, lime, limegreen, linen, magenta, maroon, mediumaquamarine, mediumblue, mediumorchid, mediumpurple, mediumseagreen, mediumslateblue, mediumspringgreen, mediumturquoise, mediumvioletred, midnightblue, mintcream, mistyrose, moccasin, navajowhite, navy, oldlace, olive, olivedrab, orange, orangered, orchid, palegoldenrod, palegreen, paleturquoise, palevioletred, papayawhip, peachpuff, peru, pink, plum, powderblue, purple, red, rosybrown, royalblue, rebeccapurple, saddlebrown, salmon, sandybrown, seagreen, seashell, sienna, silver, skyblue, slateblue, slategray, slategrey, snow, springgreen, steelblue, tan, teal, thistle, tomato, turquoise, violet, wheat, white, whitesmoke, yellow, yellowgreen
- Returns
- Return type
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βxβ, βyβ, βzβ, βtextβ, βnameβ] joined with β+β characters (e.g. βx+yβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.box.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- Returns
- Return type
-
property
hoveronΒΆ Do the hover effects highlight individual boxes or sample points or both?
The βhoveronβ property is a flaglist and may be specified as a string containing:
Any combination of [βboxesβ, βpointsβ] joined with β+β characters (e.g. βboxes+pointsβ)
- Returns
- Return type
Any
-
property
hovertemplateΒΆ Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time- formatβs syntax %{variable|d3-time-format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time- format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.- The βhovertemplateβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertemplatesrcΒΆ Sets the source reference on Chart Studio Cloud for hovertemplate .
The βhovertemplatesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hovertextΒΆ Same as
text.- The βhovertextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
jitterΒΆ Sets the amount of jitter in the sample points drawn. If 0, the sample points align along the distribution axis. If 1, the sample points are drawn in a random jitter of width equal to the width of the box(es).
- The βjitterβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
lineΒΆ The βlineβ property is an instance of Line that may be specified as:
An instance of
plotly.graph_objects.box.LineA dict of string/value properties that will be passed to the Line constructor
Supported dict properties:
- color
Sets the color of line bounding the box(es).
- width
Sets the width (in px) of line bounding the box(es).
- Returns
- Return type
-
property
lowerfenceΒΆ Sets the lower fence values. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. If
lowerfenceis not provided but a sample (inyorx) is set, we compute the lower as the last sample point below 1.5 times the IQR.The βlowerfenceβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
lowerfencesrcΒΆ Sets the source reference on Chart Studio Cloud for lowerfence .
The βlowerfencesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
markerΒΆ The βmarkerβ property is an instance of Marker that may be specified as:
An instance of
plotly.graph_objects.box.MarkerA dict of string/value properties that will be passed to the Marker constructor
Supported dict properties:
- color
Sets themarkercolor. It accepts either a specific color or an array of numbers that are mapped to the colorscale relative to the max and min values of the array or relative to
marker.cminandmarker.cmaxif set.- line
plotly.graph_objects.box.marker.Lineinstance or dict with compatible properties- opacity
Sets the marker opacity.
- outliercolor
Sets the color of the outlier sample points.
- size
Sets the marker size (in px).
- symbol
Sets the marker symbol type. Adding 100 is equivalent to appending β-openβ to a symbol name. Adding 200 is equivalent to appending β-dotβ to a symbol name. Adding 300 is equivalent to appending β-open-dotβ or βdot- openβ to a symbol name.
- Returns
- Return type
-
property
meanΒΆ Sets the mean values. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. If
meanis not provided but a sample (inyorx) is set, we compute the mean for each box using the sample values.The βmeanβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
meansrcΒΆ Sets the source reference on Chart Studio Cloud for mean .
The βmeansrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
medianΒΆ Sets the median values. There should be as many items as the number of boxes desired.
The βmedianβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
mediansrcΒΆ Sets the source reference on Chart Studio Cloud for median .
The βmediansrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover. For box traces, the name will also be used for the position coordinate, if
xandx0(yandy0if horizontal) are missing and the position axis is categorical- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
notchedΒΆ Determines whether or not notches are drawn. Notches displays a confidence interval around the median. We compute the confidence interval as median +/- 1.57 * IQR / sqrt(N), where IQR is the interquartile range and N is the sample size. If two boxesβ notches do not overlap there is 95% confidence their medians differ. See https://sites.google.com/site/davidsstatistics/home/notched- box-plots for more info. Defaults to False unless
notchwidthornotchspanis set.The βnotchedβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
notchspanΒΆ Sets the notch span from the boxesβ
medianvalues. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. Ifnotchspanis not provided but a sample (inyorx) is set, we compute it as 1.57 * IQR / sqrt(N), where N is the sample size.The βnotchspanβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
notchspansrcΒΆ Sets the source reference on Chart Studio Cloud for notchspan .
The βnotchspansrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
notchwidthΒΆ Sets the width of the notches relative to the boxβ width. For example, with 0, the notches are as wide as the box(es).
- The βnotchwidthβ property is a number and may be specified as:
An int or float in the interval [0, 0.5]
- Returns
- Return type
int|float
-
property
offsetgroupΒΆ Set several traces linked to the same position axis or matching axes to the same offsetgroup where bars of the same position coordinate will line up.
- The βoffsetgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the trace.
- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
orientationΒΆ Sets the orientation of the box(es). If βvβ (βhβ), the distribution is visualized along the vertical (horizontal).
- The βorientationβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βvβ, βhβ]
- Returns
- Return type
Any
-
property
pointposΒΆ Sets the position of the sample points in relation to the box(es). If 0, the sample points are places over the center of the box(es). Positive (negative) values correspond to positions to the right (left) for vertical boxes and above (below) for horizontal boxes
- The βpointposβ property is a number and may be specified as:
An int or float in the interval [-2, 2]
- Returns
- Return type
int|float
-
property
q1ΒΆ Sets the Quartile 1 values. There should be as many items as the number of boxes desired.
The βq1β property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
q1srcΒΆ Sets the source reference on Chart Studio Cloud for q1 .
The βq1srcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
q3ΒΆ Sets the Quartile 3 values. There should be as many items as the number of boxes desired.
The βq3β property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
q3srcΒΆ Sets the source reference on Chart Studio Cloud for q3 .
The βq3srcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
quartilemethodΒΆ Sets the method used to compute the sampleβs Q1 and Q3 quartiles. The βlinearβ method uses the 25th percentile for Q1 and 75th percentile for Q3 as computed using method #10 (listed on http://www.amstat.org/publications/jse/v14n3/langford.html). The βexclusiveβ method uses the median to divide the ordered dataset into two halves if the sample is odd, it does not include the median in either half - Q1 is then the median of the lower half and Q3 the median of the upper half. The βinclusiveβ method also uses the median to divide the ordered dataset into two halves but if the sample is odd, it includes the median in both halves - Q1 is then the median of the lower half and Q3 the median of the upper half.
- The βquartilemethodβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βlinearβ, βexclusiveβ, βinclusiveβ]
- Returns
- Return type
Any
-
property
sdΒΆ Sets the standard deviation values. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. If
sdis not provided but a sample (inyorx) is set, we compute the standard deviation for each box using the sample values.The βsdβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
sdsrcΒΆ Sets the source reference on Chart Studio Cloud for sd .
The βsdsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
selectedΒΆ The βselectedβ property is an instance of Selected that may be specified as:
An instance of
plotly.graph_objects.box.SelectedA dict of string/value properties that will be passed to the Selected constructor
Supported dict properties:
- marker
plotly.graph_objects.box.selected.Marke rinstance or dict with compatible properties
- Returns
- Return type
-
property
selectedpointsΒΆ Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.The βselectedpointsβ property accepts values of any type
- Returns
- Return type
Any
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.box.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
textΒΆ Sets the text elements associated with each sample value. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this traceβs (x,y) coordinates. To be seen, trace
hoverinfomust contain a βtextβ flag.- The βtextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
unselectedΒΆ The βunselectedβ property is an instance of Unselected that may be specified as:
An instance of
plotly.graph_objects.box.UnselectedA dict of string/value properties that will be passed to the Unselected constructor
Supported dict properties:
- marker
plotly.graph_objects.box.unselected.Mar kerinstance or dict with compatible properties
- Returns
- Return type
-
property
upperfenceΒΆ Sets the upper fence values. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. If
upperfenceis not provided but a sample (inyorx) is set, we compute the lower as the last sample point above 1.5 times the IQR.The βupperfenceβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
upperfencesrcΒΆ Sets the source reference on Chart Studio Cloud for upperfence .
The βupperfencesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
whiskerwidthΒΆ Sets the width of the whiskers relative to the boxβ width. For example, with 1, the whiskers are as wide as the box(es).
- The βwhiskerwidthβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
widthΒΆ Sets the width of the box in data coordinate If 0 (default value) the width is automatically selected based on the positions of other box traces in the same subplot.
- The βwidthβ property is a number and may be specified as:
An int or float in the interval [0, inf]
- Returns
- Return type
int|float
-
property
xΒΆ Sets the x sample data or coordinates. See overview for more info.
The βxβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
x0ΒΆ Sets the x coordinate for single-box traces or the starting coordinate for multi-box traces set using q1/median/q3. See overview for more info.
The βx0β property accepts values of any type
- Returns
- Return type
Any
-
property
xaxisΒΆ Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.The βxaxisβ property is an identifier of a particular subplot, of type βxβ, that may be specified as the string βxβ optionally followed by an integer >= 1 (e.g. βxβ, βx1β, βx2β, βx3β, etc.)
- Returns
- Return type
-
property
xcalendarΒΆ Sets the calendar system to use with
xdate data.- The βxcalendarβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βgregorianβ, βchineseβ, βcopticβ, βdiscworldβ, βethiopianβ, βhebrewβ, βislamicβ, βjulianβ, βmayanβ, βnanakshahiβ, βnepaliβ, βpersianβ, βjalaliβ, βtaiwanβ, βthaiβ, βummalquraβ]
- Returns
- Return type
Any
-
property
xsrcΒΆ Sets the source reference on Chart Studio Cloud for x .
The βxsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
yΒΆ Sets the y sample data or coordinates. See overview for more info.
The βyβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
y0ΒΆ Sets the y coordinate for single-box traces or the starting coordinate for multi-box traces set using q1/median/q3. See overview for more info.
The βy0β property accepts values of any type
- Returns
- Return type
Any
-
property
yaxisΒΆ Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.The βyaxisβ property is an identifier of a particular subplot, of type βyβ, that may be specified as the string βyβ optionally followed by an integer >= 1 (e.g. βyβ, βy1β, βy2β, βy3β, etc.)
- Returns
- Return type
-
property
ycalendarΒΆ Sets the calendar system to use with
ydate data.- The βycalendarβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βgregorianβ, βchineseβ, βcopticβ, βdiscworldβ, βethiopianβ, βhebrewβ, βislamicβ, βjulianβ, βmayanβ, βnanakshahiβ, βnepaliβ, βpersianβ, βjalaliβ, βtaiwanβ, βthaiβ, βummalquraβ]
- Returns
- Return type
Any
-
property
-
class
plotly.graph_objects.Candlestick(arg=None, close=None, closesrc=None, customdata=None, customdatasrc=None, decreasing=None, high=None, highsrc=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, increasing=None, legendgroup=None, line=None, low=None, lowsrc=None, meta=None, metasrc=None, name=None, opacity=None, open=None, opensrc=None, selectedpoints=None, showlegend=None, stream=None, text=None, textsrc=None, uid=None, uirevision=None, visible=None, whiskerwidth=None, x=None, xaxis=None, xcalendar=None, xsrc=None, yaxis=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
closeΒΆ Sets the close values.
The βcloseβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
closesrcΒΆ Sets the source reference on Chart Studio Cloud for close .
The βclosesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
decreasingΒΆ The βdecreasingβ property is an instance of Decreasing that may be specified as:
An instance of
plotly.graph_objects.candlestick.DecreasingA dict of string/value properties that will be passed to the Decreasing constructor
Supported dict properties:
- fillcolor
Sets the fill color. Defaults to a half- transparent variant of the line color, marker color, or marker line color, whichever is available.
- line
plotly.graph_objects.candlestick.decrea sing.Lineinstance or dict with compatible properties
- Returns
- Return type
-
property
highΒΆ Sets the high values.
The βhighβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
highsrcΒΆ Sets the source reference on Chart Studio Cloud for high .
The βhighsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βxβ, βyβ, βzβ, βtextβ, βnameβ] joined with β+β characters (e.g. βx+yβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.candlestick.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- split
Show hover information (open, close, high, low) in separate labels.
- Returns
- Return type
-
property
hovertextΒΆ Same as
text.- The βhovertextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
increasingΒΆ The βincreasingβ property is an instance of Increasing that may be specified as:
An instance of
plotly.graph_objects.candlestick.IncreasingA dict of string/value properties that will be passed to the Increasing constructor
Supported dict properties:
- fillcolor
Sets the fill color. Defaults to a half- transparent variant of the line color, marker color, or marker line color, whichever is available.
- line
plotly.graph_objects.candlestick.increa sing.Lineinstance or dict with compatible properties
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
lineΒΆ The βlineβ property is an instance of Line that may be specified as:
An instance of
plotly.graph_objects.candlestick.LineA dict of string/value properties that will be passed to the Line constructor
Supported dict properties:
- width
Sets the width (in px) of line bounding the box(es). Note that this style setting can also be set per direction via
increasing.line.widthanddecreasing.line.width.
- Returns
- Return type
-
property
lowΒΆ Sets the low values.
The βlowβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
lowsrcΒΆ Sets the source reference on Chart Studio Cloud for low .
The βlowsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the trace.
- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
openΒΆ Sets the open values.
The βopenβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
opensrcΒΆ Sets the source reference on Chart Studio Cloud for open .
The βopensrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
selectedpointsΒΆ Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.The βselectedpointsβ property accepts values of any type
- Returns
- Return type
Any
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.candlestick.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
textΒΆ Sets hover text elements associated with each sample point. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to this traceβs sample points.
- The βtextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
whiskerwidthΒΆ Sets the width of the whiskers relative to the boxβ width. For example, with 1, the whiskers are as wide as the box(es).
- The βwhiskerwidthβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
xΒΆ Sets the x coordinates. If absent, linear coordinate will be generated.
The βxβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
xaxisΒΆ Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.The βxaxisβ property is an identifier of a particular subplot, of type βxβ, that may be specified as the string βxβ optionally followed by an integer >= 1 (e.g. βxβ, βx1β, βx2β, βx3β, etc.)
- Returns
- Return type
-
property
xcalendarΒΆ Sets the calendar system to use with
xdate data.- The βxcalendarβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βgregorianβ, βchineseβ, βcopticβ, βdiscworldβ, βethiopianβ, βhebrewβ, βislamicβ, βjulianβ, βmayanβ, βnanakshahiβ, βnepaliβ, βpersianβ, βjalaliβ, βtaiwanβ, βthaiβ, βummalquraβ]
- Returns
- Return type
Any
-
property
xsrcΒΆ Sets the source reference on Chart Studio Cloud for x .
The βxsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
yaxisΒΆ Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.The βyaxisβ property is an identifier of a particular subplot, of type βyβ, that may be specified as the string βyβ optionally followed by an integer >= 1 (e.g. βyβ, βy1β, βy2β, βy3β, etc.)
- Returns
- Return type
-
property
-
class
plotly.graph_objects.Carpet(arg=None, a=None, a0=None, aaxis=None, asrc=None, b=None, b0=None, baxis=None, bsrc=None, carpet=None, cheaterslope=None, color=None, customdata=None, customdatasrc=None, da=None, db=None, font=None, ids=None, idssrc=None, meta=None, metasrc=None, name=None, opacity=None, stream=None, uid=None, uirevision=None, visible=None, x=None, xaxis=None, xsrc=None, y=None, yaxis=None, ysrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
aΒΆ An array containing values of the first parameter value
The βaβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
a0ΒΆ Alternate to
a. Builds a linear space of a coordinates. Use withdawherea0is the starting coordinate anddathe step.- The βa0β property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
aaxisΒΆ The βaaxisβ property is an instance of Aaxis that may be specified as:
An instance of
plotly.graph_objects.carpet.AaxisA dict of string/value properties that will be passed to the Aaxis constructor
Supported dict properties:
- arraydtick
The stride between grid lines along the axis
- arraytick0
The starting index of grid lines along the axis
- autorange
Determines whether or not the range of this axis is computed in relation to the input data. See
rangemodefor more info. Ifrangeis provided, thenautorangeis set to False.- categoryarray
Sets the order in which categories on this axis appear. Only has an effect if
categoryorderis set to βarrayβ. Used withcategoryorder.- categoryarraysrc
Sets the source reference on Chart Studio Cloud for categoryarray .
- categoryorder
Specifies the ordering logic for the case of categorical variables. By default, plotly uses βtraceβ, which specifies the order that is present in the data supplied. Set
categoryorderto category ascending or category descending if order should be determined by the alphanumerical order of the category names. Setcategoryorderto βarrayβ to derive the ordering from the attributecategoryarray. If a category is not found in thecategoryarrayarray, the sorting behavior for that attribute will be identical to the βtraceβ mode. The unspecified categories will follow the categories incategoryarray.
cheatertype
- color
Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- dtick
The stride between grid lines along the axis
- endline
Determines whether or not a line is drawn at along the final value of this axis. If True, the end line is drawn on top of the grid lines.
- endlinecolor
Sets the line color of the end line.
- endlinewidth
Sets the width (in px) of the end line.
- exponentformat
Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If βnoneβ, it appears as 1,000,000,000. If βeβ, 1e+9. If βEβ, 1E+9. If βpowerβ, 1x10^9 (with 9 in a super script). If βSIβ, 1G. If βBβ, 1B.
- fixedrange
Determines whether or not this axis is zoom- able. If true, then zoom is disabled.
- gridcolor
Sets the axis line color.
- gridwidth
Sets the width (in px) of the axis line.
- labelpadding
Extra padding between label and the axis
- labelprefix
Sets a axis label prefix.
- labelsuffix
Sets a axis label suffix.
- linecolor
Sets the axis line color.
- linewidth
Sets the width (in px) of the axis line.
- minorgridcolor
Sets the color of the grid lines.
- minorgridcount
Sets the number of minor grid ticks per major grid tick
- minorgridwidth
Sets the width (in px) of the grid lines.
- nticks
Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to
nticks. Has an effect only iftickmodeis set to βautoβ.- range
Sets the range of this axis. If the axis
typeis βlogβ, then you must take the log of your desired range (e.g. to set the range from 1 to 100, set the range from 0 to 2). If the axistypeis βdateβ, it should be date strings, like date data, though Date objects and unix milliseconds will be accepted and converted to strings. If the axistypeis βcategoryβ, it should be numbers, using the scale where each category is assigned a serial number from zero in the order it appears.- rangemode
If βnormalβ, the range is computed in relation to the extrema of the input data. If *tozero*`, the range extends to 0, regardless of the input data If βnonnegativeβ, the range is non- negative, regardless of the input data.
- separatethousands
If βtrueβ, even 4-digit integers are separated
- showexponent
If βallβ, all exponents are shown besides their significands. If βfirstβ, only the exponent of the first tick is shown. If βlastβ, only the exponent of the last tick is shown. If βnoneβ, no exponents appear.
- showgrid
Determines whether or not grid lines are drawn. If True, the grid lines are drawn at every tick mark.
- showline
Determines whether or not a line bounding this axis is drawn.
- showticklabels
Determines whether axis labels are drawn on the low side, the high side, both, or neither side of the axis.
- showtickprefix
If βallβ, all tick labels are displayed with a prefix. If βfirstβ, only the first tick is displayed with a prefix. If βlastβ, only the last tick is displayed with a suffix. If βnoneβ, tick prefixes are hidden.
- showticksuffix
Same as
showtickprefixbut for tick suffixes.
smoothing
- startline
Determines whether or not a line is drawn at along the starting value of this axis. If True, the start line is drawn on top of the grid lines.
- startlinecolor
Sets the line color of the start line.
- startlinewidth
Sets the width (in px) of the start line.
- tick0
The starting index of grid lines along the axis
- tickangle
Sets the angle of the tick labels with respect to the horizontal. For example, a
tickangleof -90 draws the tick labels vertically.- tickfont
Sets the tick font.
- tickformat
Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format And for dates see: We add one item to d3βs date formatter: β%{n}fβ for fractional seconds with n digits. For example, 2016-10-13 09:15:23.456 with tickformat β%H~%M~%S.%2fβ would display β09~15~23.46β
- tickformatstops
A tuple of
plotly.graph_objects.carpet. aaxis.Tickformatstopinstances or dicts with compatible properties- tickformatstopdefaults
When used in a template (as layout.template.dat a.carpet.aaxis.tickformatstopdefaults), sets the default property values to use for elements of carpet.aaxis.tickformatstops
tickmode
- tickprefix
Sets a tick label prefix.
- ticksuffix
Sets a tick label suffix.
- ticktext
Sets the text displayed at the ticks position via
tickvals. Only has an effect iftickmodeis set to βarrayβ. Used withtickvals.- ticktextsrc
Sets the source reference on Chart Studio Cloud for ticktext .
- tickvals
Sets the values at which ticks on this axis appear. Only has an effect if
tickmodeis set to βarrayβ. Used withticktext.- tickvalssrc
Sets the source reference on Chart Studio Cloud for tickvals .
- title
:class:`plotly.graph_objects.carpet.aaxis.Title ` instance or dict with compatible properties
- titlefont
Deprecated: Please use carpet.aaxis.title.font instead. Sets this axisβ title font. Note that the titleβs font used to be set by the now deprecated
titlefontattribute.- titleoffset
Deprecated: Please use carpet.aaxis.title.offset instead. An additional amount by which to offset the title from the tick labels, given in pixels. Note that this used to be set by the now deprecated
titleoffsetattribute.- type
Sets the axis type. By default, plotly attempts to determined the axis type by looking into the data of the traces that referenced the axis in question.
- Returns
- Return type
-
property
asrcΒΆ Sets the source reference on Chart Studio Cloud for a .
The βasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
bΒΆ A two dimensional array of y coordinates at each carpet point.
The βbβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
b0ΒΆ Alternate to
b. Builds a linear space of a coordinates. Use withdbwhereb0is the starting coordinate anddbthe step.- The βb0β property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
baxisΒΆ The βbaxisβ property is an instance of Baxis that may be specified as:
An instance of
plotly.graph_objects.carpet.BaxisA dict of string/value properties that will be passed to the Baxis constructor
Supported dict properties:
- arraydtick
The stride between grid lines along the axis
- arraytick0
The starting index of grid lines along the axis
- autorange
Determines whether or not the range of this axis is computed in relation to the input data. See
rangemodefor more info. Ifrangeis provided, thenautorangeis set to False.- categoryarray
Sets the order in which categories on this axis appear. Only has an effect if
categoryorderis set to βarrayβ. Used withcategoryorder.- categoryarraysrc
Sets the source reference on Chart Studio Cloud for categoryarray .
- categoryorder
Specifies the ordering logic for the case of categorical variables. By default, plotly uses βtraceβ, which specifies the order that is present in the data supplied. Set
categoryorderto category ascending or category descending if order should be determined by the alphanumerical order of the category names. Setcategoryorderto βarrayβ to derive the ordering from the attributecategoryarray. If a category is not found in thecategoryarrayarray, the sorting behavior for that attribute will be identical to the βtraceβ mode. The unspecified categories will follow the categories incategoryarray.
cheatertype
- color
Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- dtick
The stride between grid lines along the axis
- endline
Determines whether or not a line is drawn at along the final value of this axis. If True, the end line is drawn on top of the grid lines.
- endlinecolor
Sets the line color of the end line.
- endlinewidth
Sets the width (in px) of the end line.
- exponentformat
Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If βnoneβ, it appears as 1,000,000,000. If βeβ, 1e+9. If βEβ, 1E+9. If βpowerβ, 1x10^9 (with 9 in a super script). If βSIβ, 1G. If βBβ, 1B.
- fixedrange
Determines whether or not this axis is zoom- able. If true, then zoom is disabled.
- gridcolor
Sets the axis line color.
- gridwidth
Sets the width (in px) of the axis line.
- labelpadding
Extra padding between label and the axis
- labelprefix
Sets a axis label prefix.
- labelsuffix
Sets a axis label suffix.
- linecolor
Sets the axis line color.
- linewidth
Sets the width (in px) of the axis line.
- minorgridcolor
Sets the color of the grid lines.
- minorgridcount
Sets the number of minor grid ticks per major grid tick
- minorgridwidth
Sets the width (in px) of the grid lines.
- nticks
Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to
nticks. Has an effect only iftickmodeis set to βautoβ.- range
Sets the range of this axis. If the axis
typeis βlogβ, then you must take the log of your desired range (e.g. to set the range from 1 to 100, set the range from 0 to 2). If the axistypeis βdateβ, it should be date strings, like date data, though Date objects and unix milliseconds will be accepted and converted to strings. If the axistypeis βcategoryβ, it should be numbers, using the scale where each category is assigned a serial number from zero in the order it appears.- rangemode
If βnormalβ, the range is computed in relation to the extrema of the input data. If *tozero*`, the range extends to 0, regardless of the input data If βnonnegativeβ, the range is non- negative, regardless of the input data.
- separatethousands
If βtrueβ, even 4-digit integers are separated
- showexponent
If βallβ, all exponents are shown besides their significands. If βfirstβ, only the exponent of the first tick is shown. If βlastβ, only the exponent of the last tick is shown. If βnoneβ, no exponents appear.
- showgrid
Determines whether or not grid lines are drawn. If True, the grid lines are drawn at every tick mark.
- showline
Determines whether or not a line bounding this axis is drawn.
- showticklabels
Determines whether axis labels are drawn on the low side, the high side, both, or neither side of the axis.
- showtickprefix
If βallβ, all tick labels are displayed with a prefix. If βfirstβ, only the first tick is displayed with a prefix. If βlastβ, only the last tick is displayed with a suffix. If βnoneβ, tick prefixes are hidden.
- showticksuffix
Same as
showtickprefixbut for tick suffixes.
smoothing
- startline
Determines whether or not a line is drawn at along the starting value of this axis. If True, the start line is drawn on top of the grid lines.
- startlinecolor
Sets the line color of the start line.
- startlinewidth
Sets the width (in px) of the start line.
- tick0
The starting index of grid lines along the axis
- tickangle
Sets the angle of the tick labels with respect to the horizontal. For example, a
tickangleof -90 draws the tick labels vertically.- tickfont
Sets the tick font.
- tickformat
Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format And for dates see: We add one item to d3βs date formatter: β%{n}fβ for fractional seconds with n digits. For example, 2016-10-13 09:15:23.456 with tickformat β%H~%M~%S.%2fβ would display β09~15~23.46β
- tickformatstops
A tuple of
plotly.graph_objects.carpet. baxis.Tickformatstopinstances or dicts with compatible properties- tickformatstopdefaults
When used in a template (as layout.template.dat a.carpet.baxis.tickformatstopdefaults), sets the default property values to use for elements of carpet.baxis.tickformatstops
tickmode
- tickprefix
Sets a tick label prefix.
- ticksuffix
Sets a tick label suffix.
- ticktext
Sets the text displayed at the ticks position via
tickvals. Only has an effect iftickmodeis set to βarrayβ. Used withtickvals.- ticktextsrc
Sets the source reference on Chart Studio Cloud for ticktext .
- tickvals
Sets the values at which ticks on this axis appear. Only has an effect if
tickmodeis set to βarrayβ. Used withticktext.- tickvalssrc
Sets the source reference on Chart Studio Cloud for tickvals .
- title
:class:`plotly.graph_objects.carpet.baxis.Title ` instance or dict with compatible properties
- titlefont
Deprecated: Please use carpet.baxis.title.font instead. Sets this axisβ title font. Note that the titleβs font used to be set by the now deprecated
titlefontattribute.- titleoffset
Deprecated: Please use carpet.baxis.title.offset instead. An additional amount by which to offset the title from the tick labels, given in pixels. Note that this used to be set by the now deprecated
titleoffsetattribute.- type
Sets the axis type. By default, plotly attempts to determined the axis type by looking into the data of the traces that referenced the axis in question.
- Returns
- Return type
-
property
bsrcΒΆ Sets the source reference on Chart Studio Cloud for b .
The βbsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
carpetΒΆ An identifier for this carpet, so that
scattercarpetandcontourcarpettraces can specify a carpet plot on which they lie- The βcarpetβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
cheaterslopeΒΆ The shift applied to each successive row of data in creating a cheater plot. Only used if
xis been ommitted.- The βcheaterslopeβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
colorΒΆ Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
- The βcolorβ property is a color and may be specified as:
A hex string (e.g. β#ff0000β)
An rgb/rgba string (e.g. βrgb(255,0,0)β)
An hsl/hsla string (e.g. βhsl(0,100%,50%)β)
An hsv/hsva string (e.g. βhsv(0,100%,100%)β)
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure, beige, bisque, black, blanchedalmond, blue, blueviolet, brown, burlywood, cadetblue, chartreuse, chocolate, coral, cornflowerblue, cornsilk, crimson, cyan, darkblue, darkcyan, darkgoldenrod, darkgray, darkgrey, darkgreen, darkkhaki, darkmagenta, darkolivegreen, darkorange, darkorchid, darkred, darksalmon, darkseagreen, darkslateblue, darkslategray, darkslategrey, darkturquoise, darkviolet, deeppink, deepskyblue, dimgray, dimgrey, dodgerblue, firebrick, floralwhite, forestgreen, fuchsia, gainsboro, ghostwhite, gold, goldenrod, gray, grey, green, greenyellow, honeydew, hotpink, indianred, indigo, ivory, khaki, lavender, lavenderblush, lawngreen, lemonchiffon, lightblue, lightcoral, lightcyan, lightgoldenrodyellow, lightgray, lightgrey, lightgreen, lightpink, lightsalmon, lightseagreen, lightskyblue, lightslategray, lightslategrey, lightsteelblue, lightyellow, lime, limegreen, linen, magenta, maroon, mediumaquamarine, mediumblue, mediumorchid, mediumpurple, mediumseagreen, mediumslateblue, mediumspringgreen, mediumturquoise, mediumvioletred, midnightblue, mintcream, mistyrose, moccasin, navajowhite, navy, oldlace, olive, olivedrab, orange, orangered, orchid, palegoldenrod, palegreen, paleturquoise, palevioletred, papayawhip, peachpuff, peru, pink, plum, powderblue, purple, red, rosybrown, royalblue, rebeccapurple, saddlebrown, salmon, sandybrown, seagreen, seashell, sienna, silver, skyblue, slateblue, slategray, slategrey, snow, springgreen, steelblue, tan, teal, thistle, tomato, turquoise, violet, wheat, white, whitesmoke, yellow, yellowgreen
- Returns
- Return type
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
daΒΆ Sets the a coordinate step. See
a0for more info.- The βdaβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
dbΒΆ Sets the b coordinate step. See
b0for more info.- The βdbβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
fontΒΆ The default font used for axis & tick labels on this carpet
The βfontβ property is an instance of Font that may be specified as:
An instance of
plotly.graph_objects.carpet.FontA dict of string/value properties that will be passed to the Font constructor
Supported dict properties:
color
- family
HTML font family - the typeface that will be applied by the web browser. The web browser will only be able to apply a font if it is available on the system which it operates. Provide multiple font families, separated by commas, to indicate the preference in which to apply fonts if they arenβt available on the system. The Chart Studio Cloud (at https://chart-studio.plotly.com or on-premise) generates images on a server, where only a select number of fonts are installed and supported. These include βArialβ, βBaltoβ, βCourier Newβ, βDroid Sansβ,, βDroid Serifβ, βDroid Sans Monoβ, βGravitas Oneβ, βOld Standard TTβ, βOpen Sansβ, βOverpassβ, βPT Sans Narrowβ, βRalewayβ, βTimes New Romanβ.
size
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the trace.
- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.carpet.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
xΒΆ A two dimensional array of x coordinates at each carpet point. If ommitted, the plot is a cheater plot and the xaxis is hidden by default.
The βxβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
xaxisΒΆ Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.The βxaxisβ property is an identifier of a particular subplot, of type βxβ, that may be specified as the string βxβ optionally followed by an integer >= 1 (e.g. βxβ, βx1β, βx2β, βx3β, etc.)
- Returns
- Return type
-
property
xsrcΒΆ Sets the source reference on Chart Studio Cloud for x .
The βxsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
yΒΆ A two dimensional array of y coordinates at each carpet point.
The βyβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
yaxisΒΆ Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.The βyaxisβ property is an identifier of a particular subplot, of type βyβ, that may be specified as the string βyβ optionally followed by an integer >= 1 (e.g. βyβ, βy1β, βy2β, βy3β, etc.)
- Returns
- Return type
-
property
-
class
plotly.graph_objects.Choropleth(arg=None, autocolorscale=None, coloraxis=None, colorbar=None, colorscale=None, customdata=None, customdatasrc=None, featureidkey=None, geo=None, geojson=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, legendgroup=None, locationmode=None, locations=None, locationssrc=None, marker=None, meta=None, metasrc=None, name=None, reversescale=None, selected=None, selectedpoints=None, showlegend=None, showscale=None, stream=None, text=None, textsrc=None, uid=None, uirevision=None, unselected=None, visible=None, z=None, zauto=None, zmax=None, zmid=None, zmin=None, zsrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
autocolorscaleΒΆ Determines whether the colorscale is a default palette (
autocolorscale: true) or the palette determined bycolorscale. In casecolorscaleis unspecified orautocolorscaleis true, the default palette will be chosen according to whether numbers in thecolorarray are all positive, all negative or mixed.The βautocolorscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
coloraxisΒΆ Sets a reference to a shared color axis. References to these shared color axes are βcoloraxisβ, βcoloraxis2β, βcoloraxis3β, etc. Settings for these shared color axes are set in the layout, under
layout.coloraxis,layout.coloraxis2, etc. Note that multiple color scales can be linked to the same color axis.The βcoloraxisβ property is an identifier of a particular subplot, of type βcoloraxisβ, that may be specified as the string βcoloraxisβ optionally followed by an integer >= 1 (e.g. βcoloraxisβ, βcoloraxis1β, βcoloraxis2β, βcoloraxis3β, etc.)
- Returns
- Return type
-
property
colorbarΒΆ The βcolorbarβ property is an instance of ColorBar that may be specified as:
An instance of
plotly.graph_objects.choropleth.ColorBarA dict of string/value properties that will be passed to the ColorBar constructor
Supported dict properties:
- bgcolor
Sets the color of padded area.
- bordercolor
Sets the axis line color.
- borderwidth
Sets the width (in px) or the border enclosing this color bar.
- dtick
Sets the step in-between ticks on this axis. Use with
tick0. Must be a positive number, or special strings available to βlogβ and βdateβ axes. If the axistypeis βlogβ, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, β¦ set dtick to 1. To set tick marks at 1, 100, 10000, β¦ set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, β¦ set dtick to log_10(5), or 0.69897000433. βlogβ has several special values; βL<f>β, wherefis a positive number, gives ticks linearly spaced in value (but not position). For exampletick0= 0.1,dtick= βL0.5β will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use βD1β (all digits) or βD2β (only 2 and 5).tick0is ignored for βD1β and βD2β. If the axistypeis βdateβ, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, setdtickto 86400000.0. βdateβ also has special values βM<n>β gives ticks spaced by a number of months.nmust be a positive integer. To set ticks on the 15th of every third month, settick0to β2000-01-15β anddtickto βM3β. To set ticks every 4 years, setdtickto βM48β- exponentformat
Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If βnoneβ, it appears as 1,000,000,000. If βeβ, 1e+9. If βEβ, 1E+9. If βpowerβ, 1x10^9 (with 9 in a super script). If βSIβ, 1G. If βBβ, 1B.
- len
Sets the length of the color bar This measure excludes the padding of both ends. That is, the color bar length is this length minus the padding on both ends.
- lenmode
Determines whether this color barβs length (i.e. the measure in the color variation direction) is set in units of plot βfractionβ or in *pixels. Use
lento set the value.- nticks
Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to
nticks. Has an effect only iftickmodeis set to βautoβ.- outlinecolor
Sets the axis line color.
- outlinewidth
Sets the width (in px) of the axis line.
- separatethousands
If βtrueβ, even 4-digit integers are separated
- showexponent
If βallβ, all exponents are shown besides their significands. If βfirstβ, only the exponent of the first tick is shown. If βlastβ, only the exponent of the last tick is shown. If βnoneβ, no exponents appear.
- showticklabels
Determines whether or not the tick labels are drawn.
- showtickprefix
If βallβ, all tick labels are displayed with a prefix. If βfirstβ, only the first tick is displayed with a prefix. If βlastβ, only the last tick is displayed with a suffix. If βnoneβ, tick prefixes are hidden.
- showticksuffix
Same as
showtickprefixbut for tick suffixes.- thickness
Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
- thicknessmode
Determines whether this color barβs thickness (i.e. the measure in the constant color direction) is set in units of plot βfractionβ or in βpixelsβ. Use
thicknessto set the value.- tick0
Sets the placement of the first tick on this axis. Use with
dtick. If the axistypeis βlogβ, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set thetick0to 2) except whendtick`=*L<f>* (see `dtickfor more info). If the axistypeis βdateβ, it should be a date string, like date data. If the axistypeis βcategoryβ, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.- tickangle
Sets the angle of the tick labels with respect to the horizontal. For example, a
tickangleof -90 draws the tick labels vertically.- tickcolor
Sets the tick color.
- tickfont
Sets the color barβs tick label font
- tickformat
Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format And for dates see: https://github.com/d3/d3-time- format#locale_format We add one item to d3βs date formatter: β%{n}fβ for fractional seconds with n digits. For example, 2016-10-13 09:15:23.456 with tickformat β%H~%M~%S.%2fβ would display β09~15~23.46β
- tickformatstops
A tuple of
plotly.graph_objects.choropl eth.colorbar.Tickformatstopinstances or dicts with compatible properties- tickformatstopdefaults
When used in a template (as layout.template.dat a.choropleth.colorbar.tickformatstopdefaults), sets the default property values to use for elements of choropleth.colorbar.tickformatstops
- ticklen
Sets the tick length (in px).
- tickmode
Sets the tick mode for this axis. If βautoβ, the number of ticks is set via
nticks. If βlinearβ, the placement of the ticks is determined by a starting positiontick0and a tick stepdtick(βlinearβ is the default value iftick0anddtickare provided). If βarrayβ, the placement of the ticks is set viatickvalsand the tick text isticktext. (βarrayβ is the default value iftickvalsis provided).- tickprefix
Sets a tick label prefix.
- ticks
Determines whether ticks are drawn or not. If ββ, this axisβ ticks are not drawn. If βoutsideβ (βinsideβ), this axisβ are drawn outside (inside) the axis lines.
- ticksuffix
Sets a tick label suffix.
- ticktext
Sets the text displayed at the ticks position via
tickvals. Only has an effect iftickmodeis set to βarrayβ. Used withtickvals.- ticktextsrc
Sets the source reference on Chart Studio Cloud for ticktext .
- tickvals
Sets the values at which ticks on this axis appear. Only has an effect if
tickmodeis set to βarrayβ. Used withticktext.- tickvalssrc
Sets the source reference on Chart Studio Cloud for tickvals .
- tickwidth
Sets the tick width (in px).
- title
plotly.graph_objects.choropleth.colorba r.Titleinstance or dict with compatible properties- titlefont
Deprecated: Please use choropleth.colorbar.title.font instead. Sets this color barβs title font. Note that the titleβs font used to be set by the now deprecated
titlefontattribute.- titleside
Deprecated: Please use choropleth.colorbar.title.side instead. Determines the location of color barβs title with respect to the color bar. Note that the titleβs location used to be set by the now deprecated
titlesideattribute.- x
Sets the x position of the color bar (in plot fraction).
- xanchor
Sets this color barβs horizontal position anchor. This anchor binds the
xposition to the βleftβ, βcenterβ or βrightβ of the color bar.- xpad
Sets the amount of padding (in px) along the x direction.
- y
Sets the y position of the color bar (in plot fraction).
- yanchor
Sets this color barβs vertical position anchor This anchor binds the
yposition to the βtopβ, βmiddleβ or βbottomβ of the color bar.- ypad
Sets the amount of padding (in px) along the y direction.
- Returns
- Return type
-
property
colorscaleΒΆ Sets the colorscale. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example,
[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]. To control the bounds of the colorscale in color space, use`zmin` andzmax. Alternatively,colorscalemay be a palette name string of the following list: Greys,YlGnBu,Greens,YlOrRd,Bluered,RdBu,Reds,Bl ues,Picnic,Rainbow,Portland,Jet,Hot,Blackbody,Earth,Electric,Vi ridis,Cividis.The βcolorscaleβ property is a colorscale and may be specified as:
A list of colors that will be spaced evenly to create the colorscale. Many predefined colorscale lists are included in the sequential, diverging, and cyclical modules in the plotly.colors package.
A list of 2-element lists where the first element is the normalized color level value (starting at 0 and ending at 1), and the second item is a valid color string. (e.g. [[0, βgreenβ], [0.5, βredβ], [1.0, βrgb(0, 0, 255)β]])
- One of the following named colorscales:
- [βaggrnylβ, βagsunsetβ, βalgaeβ, βampβ, βarmyroseβ, βbalanceβ,
βblackbodyβ, βblueredβ, βbluesβ, βblugrnβ, βbluylβ, βbrbgβ, βbrwnylβ, βbugnβ, βbupuβ, βburgβ, βburgylβ, βcividisβ, βcurlβ, βdarkmintβ, βdeepβ, βdeltaβ, βdenseβ, βearthβ, βedgeβ, βelectricβ, βemrldβ, βfallβ, βgeyserβ, βgnbuβ, βgrayβ, βgreensβ, βgreysβ, βhalineβ, βhotβ, βhsvβ, βiceβ, βicefireβ, βinfernoβ, βjetβ, βmagentaβ, βmagmaβ, βmatterβ, βmintβ, βmrybmβ, βmygbmβ, βorangesβ, βorrdβ, βoryelβ, βpeachβ, βphaseβ, βpicnicβ, βpinkylβ, βpiygβ, βplasmaβ, βplotly3β, βportlandβ, βprgnβ, βpubuβ, βpubugnβ, βpuorβ, βpurdβ, βpurpβ, βpurplesβ, βpurporβ, βrainbowβ, βrdbuβ, βrdgyβ, βrdpuβ, βrdylbuβ, βrdylgnβ, βredorβ, βredsβ, βsolarβ, βspectralβ, βspeedβ, βsunsetβ, βsunsetdarkβ, βtealβ, βtealgrnβ, βtealroseβ, βtempoβ, βtempsβ, βthermalβ, βtropicβ, βturbidβ, βtwilightβ, βviridisβ, βylgnβ, βylgnbuβ, βylorbrβ, βylorrdβ].
Appending β_rβ to a named colorscale reverses it.
- Returns
- Return type
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
featureidkeyΒΆ Sets the key in GeoJSON features which is used as id to match the items included in the
locationsarray. Only has an effect whengeojsonis set. Support nested property, for example βproperties.nameβ.- The βfeatureidkeyβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
geoΒΆ Sets a reference between this traceβs geospatial coordinates and a geographic map. If βgeoβ (the default value), the geospatial coordinates refer to
layout.geo. If βgeo2β, the geospatial coordinates refer tolayout.geo2, and so on.The βgeoβ property is an identifier of a particular subplot, of type βgeoβ, that may be specified as the string βgeoβ optionally followed by an integer >= 1 (e.g. βgeoβ, βgeo1β, βgeo2β, βgeo3β, etc.)
- Returns
- Return type
-
property
geojsonΒΆ Sets optional GeoJSON data associated with this trace. If not given, the features on the base map are used. It can be set as a valid GeoJSON object or as a URL string. Note that we only accept GeoJSONs of type βFeatureCollectionβ or βFeatureβ with geometries of type βPolygonβ or βMultiPolygonβ.
The βgeojsonβ property accepts values of any type
- Returns
- Return type
Any
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βlocationβ, βzβ, βtextβ, βnameβ] joined with β+β characters (e.g. βlocation+zβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.choropleth.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- Returns
- Return type
-
property
hovertemplateΒΆ Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time- formatβs syntax %{variable|d3-time-format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time- format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.- The βhovertemplateβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertemplatesrcΒΆ Sets the source reference on Chart Studio Cloud for hovertemplate .
The βhovertemplatesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hovertextΒΆ Same as
text.- The βhovertextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
locationmodeΒΆ Determines the set of locations used to match entries in
locationsto regions on the map. Values βISO-3β, βUSA- statesβ, country names correspond to features on the base map and value βgeojson-idβ corresponds to features from a custom GeoJSON linked to thegeojsonattribute.- The βlocationmodeβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βISO-3β, βUSA-statesβ, βcountry namesβ, βgeojson-idβ]
- Returns
- Return type
Any
-
property
locationsΒΆ Sets the coordinates via location IDs or names. See
locationmodefor more info.The βlocationsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
locationssrcΒΆ Sets the source reference on Chart Studio Cloud for locations .
The βlocationssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
markerΒΆ The βmarkerβ property is an instance of Marker that may be specified as:
An instance of
plotly.graph_objects.choropleth.MarkerA dict of string/value properties that will be passed to the Marker constructor
Supported dict properties:
- line
plotly.graph_objects.choropleth.marker. Lineinstance or dict with compatible properties- opacity
Sets the opacity of the locations.
- opacitysrc
Sets the source reference on Chart Studio Cloud for opacity .
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
reversescaleΒΆ Reverses the color mapping if true. If true,
zminwill correspond to the last color in the array andzmaxwill correspond to the first color.The βreversescaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
selectedΒΆ The βselectedβ property is an instance of Selected that may be specified as:
An instance of
plotly.graph_objects.choropleth.SelectedA dict of string/value properties that will be passed to the Selected constructor
Supported dict properties:
- marker
plotly.graph_objects.choropleth.selecte d.Markerinstance or dict with compatible properties
- Returns
- Return type
-
property
selectedpointsΒΆ Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.The βselectedpointsβ property accepts values of any type
- Returns
- Return type
Any
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
showscaleΒΆ Determines whether or not a colorbar is displayed for this trace.
The βshowscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.choropleth.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
textΒΆ Sets the text elements associated with each location.
- The βtextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
unselectedΒΆ The βunselectedβ property is an instance of Unselected that may be specified as:
An instance of
plotly.graph_objects.choropleth.UnselectedA dict of string/value properties that will be passed to the Unselected constructor
Supported dict properties:
- marker
plotly.graph_objects.choropleth.unselec ted.Markerinstance or dict with compatible properties
- Returns
- Return type
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
zΒΆ Sets the color values.
The βzβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
zautoΒΆ Determines whether or not the color domain is computed with respect to the input data (here in
z) or the bounds set inzminandzmaxDefaults tofalsewhenzminandzmaxare set by the user.The βzautoβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
zmaxΒΆ Sets the upper bound of the color domain. Value should have the same units as in
zand if set,zminmust be set as well.- The βzmaxβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zmidΒΆ Sets the mid-point of the color domain by scaling
zminand/orzmaxto be equidistant to this point. Value should have the same units as inz. Has no effect whenzautoisfalse.- The βzmidβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zminΒΆ Sets the lower bound of the color domain. Value should have the same units as in
zand if set,zmaxmust be set as well.- The βzminβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
-
class
plotly.graph_objects.Choroplethmapbox(arg=None, autocolorscale=None, below=None, coloraxis=None, colorbar=None, colorscale=None, customdata=None, customdatasrc=None, featureidkey=None, geojson=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, legendgroup=None, locations=None, locationssrc=None, marker=None, meta=None, metasrc=None, name=None, reversescale=None, selected=None, selectedpoints=None, showlegend=None, showscale=None, stream=None, subplot=None, text=None, textsrc=None, uid=None, uirevision=None, unselected=None, visible=None, z=None, zauto=None, zmax=None, zmid=None, zmin=None, zsrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
autocolorscaleΒΆ Determines whether the colorscale is a default palette (
autocolorscale: true) or the palette determined bycolorscale. In casecolorscaleis unspecified orautocolorscaleis true, the default palette will be chosen according to whether numbers in thecolorarray are all positive, all negative or mixed.The βautocolorscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
belowΒΆ Determines if the choropleth polygons will be inserted before the layer with the specified ID. By default, choroplethmapbox traces are placed above the water layers. If set to ββ, the layer will be inserted above every existing layer.
- The βbelowβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
coloraxisΒΆ Sets a reference to a shared color axis. References to these shared color axes are βcoloraxisβ, βcoloraxis2β, βcoloraxis3β, etc. Settings for these shared color axes are set in the layout, under
layout.coloraxis,layout.coloraxis2, etc. Note that multiple color scales can be linked to the same color axis.The βcoloraxisβ property is an identifier of a particular subplot, of type βcoloraxisβ, that may be specified as the string βcoloraxisβ optionally followed by an integer >= 1 (e.g. βcoloraxisβ, βcoloraxis1β, βcoloraxis2β, βcoloraxis3β, etc.)
- Returns
- Return type
-
property
colorbarΒΆ The βcolorbarβ property is an instance of ColorBar that may be specified as:
An instance of
plotly.graph_objects.choroplethmapbox.ColorBarA dict of string/value properties that will be passed to the ColorBar constructor
Supported dict properties:
- bgcolor
Sets the color of padded area.
- bordercolor
Sets the axis line color.
- borderwidth
Sets the width (in px) or the border enclosing this color bar.
- dtick
Sets the step in-between ticks on this axis. Use with
tick0. Must be a positive number, or special strings available to βlogβ and βdateβ axes. If the axistypeis βlogβ, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, β¦ set dtick to 1. To set tick marks at 1, 100, 10000, β¦ set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, β¦ set dtick to log_10(5), or 0.69897000433. βlogβ has several special values; βL<f>β, wherefis a positive number, gives ticks linearly spaced in value (but not position). For exampletick0= 0.1,dtick= βL0.5β will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use βD1β (all digits) or βD2β (only 2 and 5).tick0is ignored for βD1β and βD2β. If the axistypeis βdateβ, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, setdtickto 86400000.0. βdateβ also has special values βM<n>β gives ticks spaced by a number of months.nmust be a positive integer. To set ticks on the 15th of every third month, settick0to β2000-01-15β anddtickto βM3β. To set ticks every 4 years, setdtickto βM48β- exponentformat
Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If βnoneβ, it appears as 1,000,000,000. If βeβ, 1e+9. If βEβ, 1E+9. If βpowerβ, 1x10^9 (with 9 in a super script). If βSIβ, 1G. If βBβ, 1B.
- len
Sets the length of the color bar This measure excludes the padding of both ends. That is, the color bar length is this length minus the padding on both ends.
- lenmode
Determines whether this color barβs length (i.e. the measure in the color variation direction) is set in units of plot βfractionβ or in *pixels. Use
lento set the value.- nticks
Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to
nticks. Has an effect only iftickmodeis set to βautoβ.- outlinecolor
Sets the axis line color.
- outlinewidth
Sets the width (in px) of the axis line.
- separatethousands
If βtrueβ, even 4-digit integers are separated
- showexponent
If βallβ, all exponents are shown besides their significands. If βfirstβ, only the exponent of the first tick is shown. If βlastβ, only the exponent of the last tick is shown. If βnoneβ, no exponents appear.
- showticklabels
Determines whether or not the tick labels are drawn.
- showtickprefix
If βallβ, all tick labels are displayed with a prefix. If βfirstβ, only the first tick is displayed with a prefix. If βlastβ, only the last tick is displayed with a suffix. If βnoneβ, tick prefixes are hidden.
- showticksuffix
Same as
showtickprefixbut for tick suffixes.- thickness
Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
- thicknessmode
Determines whether this color barβs thickness (i.e. the measure in the constant color direction) is set in units of plot βfractionβ or in βpixelsβ. Use
thicknessto set the value.- tick0
Sets the placement of the first tick on this axis. Use with
dtick. If the axistypeis βlogβ, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set thetick0to 2) except whendtick`=*L<f>* (see `dtickfor more info). If the axistypeis βdateβ, it should be a date string, like date data. If the axistypeis βcategoryβ, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.- tickangle
Sets the angle of the tick labels with respect to the horizontal. For example, a
tickangleof -90 draws the tick labels vertically.- tickcolor
Sets the tick color.
- tickfont
Sets the color barβs tick label font
- tickformat
Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format And for dates see: https://github.com/d3/d3-time- format#locale_format We add one item to d3βs date formatter: β%{n}fβ for fractional seconds with n digits. For example, 2016-10-13 09:15:23.456 with tickformat β%H~%M~%S.%2fβ would display β09~15~23.46β
- tickformatstops
A tuple of
plotly.graph_objects.choropl ethmapbox.colorbar.Tickformatstopinstances or dicts with compatible properties- tickformatstopdefaults
When used in a template (as layout.template.dat a.choroplethmapbox.colorbar.tickformatstopdefau lts), sets the default property values to use for elements of choroplethmapbox.colorbar.tickformatstops
- ticklen
Sets the tick length (in px).
- tickmode
Sets the tick mode for this axis. If βautoβ, the number of ticks is set via
nticks. If βlinearβ, the placement of the ticks is determined by a starting positiontick0and a tick stepdtick(βlinearβ is the default value iftick0anddtickare provided). If βarrayβ, the placement of the ticks is set viatickvalsand the tick text isticktext. (βarrayβ is the default value iftickvalsis provided).- tickprefix
Sets a tick label prefix.
- ticks
Determines whether ticks are drawn or not. If ββ, this axisβ ticks are not drawn. If βoutsideβ (βinsideβ), this axisβ are drawn outside (inside) the axis lines.
- ticksuffix
Sets a tick label suffix.
- ticktext
Sets the text displayed at the ticks position via
tickvals. Only has an effect iftickmodeis set to βarrayβ. Used withtickvals.- ticktextsrc
Sets the source reference on Chart Studio Cloud for ticktext .
- tickvals
Sets the values at which ticks on this axis appear. Only has an effect if
tickmodeis set to βarrayβ. Used withticktext.- tickvalssrc
Sets the source reference on Chart Studio Cloud for tickvals .
- tickwidth
Sets the tick width (in px).
- title
plotly.graph_objects.choroplethmapbox.c olorbar.Titleinstance or dict with compatible properties- titlefont
Deprecated: Please use choroplethmapbox.colorbar.title.font instead. Sets this color barβs title font. Note that the titleβs font used to be set by the now deprecated
titlefontattribute.- titleside
Deprecated: Please use choroplethmapbox.colorbar.title.side instead. Determines the location of color barβs title with respect to the color bar. Note that the titleβs location used to be set by the now deprecated
titlesideattribute.- x
Sets the x position of the color bar (in plot fraction).
- xanchor
Sets this color barβs horizontal position anchor. This anchor binds the
xposition to the βleftβ, βcenterβ or βrightβ of the color bar.- xpad
Sets the amount of padding (in px) along the x direction.
- y
Sets the y position of the color bar (in plot fraction).
- yanchor
Sets this color barβs vertical position anchor This anchor binds the
yposition to the βtopβ, βmiddleβ or βbottomβ of the color bar.- ypad
Sets the amount of padding (in px) along the y direction.
- Returns
- Return type
-
property
colorscaleΒΆ Sets the colorscale. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example,
[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]. To control the bounds of the colorscale in color space, use`zmin` andzmax. Alternatively,colorscalemay be a palette name string of the following list: Greys,YlGnBu,Greens,YlOrRd,Bluered,RdBu,Reds,Bl ues,Picnic,Rainbow,Portland,Jet,Hot,Blackbody,Earth,Electric,Vi ridis,Cividis.The βcolorscaleβ property is a colorscale and may be specified as:
A list of colors that will be spaced evenly to create the colorscale. Many predefined colorscale lists are included in the sequential, diverging, and cyclical modules in the plotly.colors package.
A list of 2-element lists where the first element is the normalized color level value (starting at 0 and ending at 1), and the second item is a valid color string. (e.g. [[0, βgreenβ], [0.5, βredβ], [1.0, βrgb(0, 0, 255)β]])
- One of the following named colorscales:
- [βaggrnylβ, βagsunsetβ, βalgaeβ, βampβ, βarmyroseβ, βbalanceβ,
βblackbodyβ, βblueredβ, βbluesβ, βblugrnβ, βbluylβ, βbrbgβ, βbrwnylβ, βbugnβ, βbupuβ, βburgβ, βburgylβ, βcividisβ, βcurlβ, βdarkmintβ, βdeepβ, βdeltaβ, βdenseβ, βearthβ, βedgeβ, βelectricβ, βemrldβ, βfallβ, βgeyserβ, βgnbuβ, βgrayβ, βgreensβ, βgreysβ, βhalineβ, βhotβ, βhsvβ, βiceβ, βicefireβ, βinfernoβ, βjetβ, βmagentaβ, βmagmaβ, βmatterβ, βmintβ, βmrybmβ, βmygbmβ, βorangesβ, βorrdβ, βoryelβ, βpeachβ, βphaseβ, βpicnicβ, βpinkylβ, βpiygβ, βplasmaβ, βplotly3β, βportlandβ, βprgnβ, βpubuβ, βpubugnβ, βpuorβ, βpurdβ, βpurpβ, βpurplesβ, βpurporβ, βrainbowβ, βrdbuβ, βrdgyβ, βrdpuβ, βrdylbuβ, βrdylgnβ, βredorβ, βredsβ, βsolarβ, βspectralβ, βspeedβ, βsunsetβ, βsunsetdarkβ, βtealβ, βtealgrnβ, βtealroseβ, βtempoβ, βtempsβ, βthermalβ, βtropicβ, βturbidβ, βtwilightβ, βviridisβ, βylgnβ, βylgnbuβ, βylorbrβ, βylorrdβ].
Appending β_rβ to a named colorscale reverses it.
- Returns
- Return type
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
featureidkeyΒΆ Sets the key in GeoJSON features which is used as id to match the items included in the
locationsarray. Support nested property, for example βproperties.nameβ.- The βfeatureidkeyβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
geojsonΒΆ Sets the GeoJSON data associated with this trace. It can be set as a valid GeoJSON object or as a URL string. Note that we only accept GeoJSONs of type βFeatureCollectionβ or βFeatureβ with geometries of type βPolygonβ or βMultiPolygonβ.
The βgeojsonβ property accepts values of any type
- Returns
- Return type
Any
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βlocationβ, βzβ, βtextβ, βnameβ] joined with β+β characters (e.g. βlocation+zβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.choroplethmapbox.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- Returns
- Return type
-
property
hovertemplateΒΆ Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time- formatβs syntax %{variable|d3-time-format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time- format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. variablepropertiesAnything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.- The βhovertemplateβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertemplatesrcΒΆ Sets the source reference on Chart Studio Cloud for hovertemplate .
The βhovertemplatesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hovertextΒΆ Same as
text.- The βhovertextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
locationsΒΆ Sets which features found in βgeojsonβ to plot using their feature
idfield.The βlocationsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
locationssrcΒΆ Sets the source reference on Chart Studio Cloud for locations .
The βlocationssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
markerΒΆ The βmarkerβ property is an instance of Marker that may be specified as:
An instance of
plotly.graph_objects.choroplethmapbox.MarkerA dict of string/value properties that will be passed to the Marker constructor
Supported dict properties:
- line
plotly.graph_objects.choroplethmapbox.m arker.Lineinstance or dict with compatible properties- opacity
Sets the opacity of the locations.
- opacitysrc
Sets the source reference on Chart Studio Cloud for opacity .
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
reversescaleΒΆ Reverses the color mapping if true. If true,
zminwill correspond to the last color in the array andzmaxwill correspond to the first color.The βreversescaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
selectedΒΆ The βselectedβ property is an instance of Selected that may be specified as:
An instance of
plotly.graph_objects.choroplethmapbox.SelectedA dict of string/value properties that will be passed to the Selected constructor
Supported dict properties:
- marker
plotly.graph_objects.choroplethmapbox.s elected.Markerinstance or dict with compatible properties
- Returns
- Return type
-
property
selectedpointsΒΆ Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.The βselectedpointsβ property accepts values of any type
- Returns
- Return type
Any
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
showscaleΒΆ Determines whether or not a colorbar is displayed for this trace.
The βshowscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.choroplethmapbox.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
subplotΒΆ Sets a reference between this traceβs data coordinates and a mapbox subplot. If βmapboxβ (the default value), the data refer to
layout.mapbox. If βmapbox2β, the data refer tolayout.mapbox2, and so on.The βsubplotβ property is an identifier of a particular subplot, of type βmapboxβ, that may be specified as the string βmapboxβ optionally followed by an integer >= 1 (e.g. βmapboxβ, βmapbox1β, βmapbox2β, βmapbox3β, etc.)
- Returns
- Return type
-
property
textΒΆ Sets the text elements associated with each location.
- The βtextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
unselectedΒΆ The βunselectedβ property is an instance of Unselected that may be specified as:
An instance of
plotly.graph_objects.choroplethmapbox.UnselectedA dict of string/value properties that will be passed to the Unselected constructor
Supported dict properties:
- marker
plotly.graph_objects.choroplethmapbox.u nselected.Markerinstance or dict with compatible properties
- Returns
- Return type
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
zΒΆ Sets the color values.
The βzβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
zautoΒΆ Determines whether or not the color domain is computed with respect to the input data (here in
z) or the bounds set inzminandzmaxDefaults tofalsewhenzminandzmaxare set by the user.The βzautoβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
zmaxΒΆ Sets the upper bound of the color domain. Value should have the same units as in
zand if set,zminmust be set as well.- The βzmaxβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zmidΒΆ Sets the mid-point of the color domain by scaling
zminand/orzmaxto be equidistant to this point. Value should have the same units as inz. Has no effect whenzautoisfalse.- The βzmidβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zminΒΆ Sets the lower bound of the color domain. Value should have the same units as in
zand if set,zmaxmust be set as well.- The βzminβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
-
class
plotly.graph_objects.ColorBar(*args, **kwargs)ΒΆ Bases:
dictplotly.graph_objects.ColorBar is deprecated.
- Please replace it with one of the following more specific types
plotly.graph_objects.scatter.marker.ColorBar
plotly.graph_objects.surface.ColorBar
etc.
-
class
plotly.graph_objects.Cone(arg=None, anchor=None, autocolorscale=None, cauto=None, cmax=None, cmid=None, cmin=None, coloraxis=None, colorbar=None, colorscale=None, customdata=None, customdatasrc=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, legendgroup=None, lighting=None, lightposition=None, meta=None, metasrc=None, name=None, opacity=None, reversescale=None, scene=None, showlegend=None, showscale=None, sizemode=None, sizeref=None, stream=None, text=None, textsrc=None, u=None, uid=None, uirevision=None, usrc=None, v=None, visible=None, vsrc=None, w=None, wsrc=None, x=None, xsrc=None, y=None, ysrc=None, z=None, zsrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
anchorΒΆ Sets the conesβ anchor with respect to their x/y/z positions. Note that βcmβ denote the coneβs center of mass which corresponds to 1/4 from the tail to tip.
- The βanchorβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βtipβ, βtailβ, βcmβ, βcenterβ]
- Returns
- Return type
Any
-
property
autocolorscaleΒΆ Determines whether the colorscale is a default palette (
autocolorscale: true) or the palette determined bycolorscale. In casecolorscaleis unspecified orautocolorscaleis true, the default palette will be chosen according to whether numbers in thecolorarray are all positive, all negative or mixed.The βautocolorscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
cautoΒΆ Determines whether or not the color domain is computed with respect to the input data (here u/v/w norm) or the bounds set in
cminandcmaxDefaults tofalsewhencminandcmaxare set by the user.The βcautoβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
cmaxΒΆ Sets the upper bound of the color domain. Value should have the same units as u/v/w norm and if set,
cminmust be set as well.- The βcmaxβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
cmidΒΆ Sets the mid-point of the color domain by scaling
cminand/orcmaxto be equidistant to this point. Value should have the same units as u/v/w norm. Has no effect whencautoisfalse.- The βcmidβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
cminΒΆ Sets the lower bound of the color domain. Value should have the same units as u/v/w norm and if set,
cmaxmust be set as well.- The βcminβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
coloraxisΒΆ Sets a reference to a shared color axis. References to these shared color axes are βcoloraxisβ, βcoloraxis2β, βcoloraxis3β, etc. Settings for these shared color axes are set in the layout, under
layout.coloraxis,layout.coloraxis2, etc. Note that multiple color scales can be linked to the same color axis.The βcoloraxisβ property is an identifier of a particular subplot, of type βcoloraxisβ, that may be specified as the string βcoloraxisβ optionally followed by an integer >= 1 (e.g. βcoloraxisβ, βcoloraxis1β, βcoloraxis2β, βcoloraxis3β, etc.)
- Returns
- Return type
-
property
colorbarΒΆ The βcolorbarβ property is an instance of ColorBar that may be specified as:
An instance of
plotly.graph_objects.cone.ColorBarA dict of string/value properties that will be passed to the ColorBar constructor
Supported dict properties:
- bgcolor
Sets the color of padded area.
- bordercolor
Sets the axis line color.
- borderwidth
Sets the width (in px) or the border enclosing this color bar.
- dtick
Sets the step in-between ticks on this axis. Use with
tick0. Must be a positive number, or special strings available to βlogβ and βdateβ axes. If the axistypeis βlogβ, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, β¦ set dtick to 1. To set tick marks at 1, 100, 10000, β¦ set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, β¦ set dtick to log_10(5), or 0.69897000433. βlogβ has several special values; βL<f>β, wherefis a positive number, gives ticks linearly spaced in value (but not position). For exampletick0= 0.1,dtick= βL0.5β will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use βD1β (all digits) or βD2β (only 2 and 5).tick0is ignored for βD1β and βD2β. If the axistypeis βdateβ, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, setdtickto 86400000.0. βdateβ also has special values βM<n>β gives ticks spaced by a number of months.nmust be a positive integer. To set ticks on the 15th of every third month, settick0to β2000-01-15β anddtickto βM3β. To set ticks every 4 years, setdtickto βM48β- exponentformat
Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If βnoneβ, it appears as 1,000,000,000. If βeβ, 1e+9. If βEβ, 1E+9. If βpowerβ, 1x10^9 (with 9 in a super script). If βSIβ, 1G. If βBβ, 1B.
- len
Sets the length of the color bar This measure excludes the padding of both ends. That is, the color bar length is this length minus the padding on both ends.
- lenmode
Determines whether this color barβs length (i.e. the measure in the color variation direction) is set in units of plot βfractionβ or in *pixels. Use
lento set the value.- nticks
Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to
nticks. Has an effect only iftickmodeis set to βautoβ.- outlinecolor
Sets the axis line color.
- outlinewidth
Sets the width (in px) of the axis line.
- separatethousands
If βtrueβ, even 4-digit integers are separated
- showexponent
If βallβ, all exponents are shown besides their significands. If βfirstβ, only the exponent of the first tick is shown. If βlastβ, only the exponent of the last tick is shown. If βnoneβ, no exponents appear.
- showticklabels
Determines whether or not the tick labels are drawn.
- showtickprefix
If βallβ, all tick labels are displayed with a prefix. If βfirstβ, only the first tick is displayed with a prefix. If βlastβ, only the last tick is displayed with a suffix. If βnoneβ, tick prefixes are hidden.
- showticksuffix
Same as
showtickprefixbut for tick suffixes.- thickness
Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
- thicknessmode
Determines whether this color barβs thickness (i.e. the measure in the constant color direction) is set in units of plot βfractionβ or in βpixelsβ. Use
thicknessto set the value.- tick0
Sets the placement of the first tick on this axis. Use with
dtick. If the axistypeis βlogβ, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set thetick0to 2) except whendtick`=*L<f>* (see `dtickfor more info). If the axistypeis βdateβ, it should be a date string, like date data. If the axistypeis βcategoryβ, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.- tickangle
Sets the angle of the tick labels with respect to the horizontal. For example, a
tickangleof -90 draws the tick labels vertically.- tickcolor
Sets the tick color.
- tickfont
Sets the color barβs tick label font
- tickformat
Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format And for dates see: https://github.com/d3/d3-time- format#locale_format We add one item to d3βs date formatter: β%{n}fβ for fractional seconds with n digits. For example, 2016-10-13 09:15:23.456 with tickformat β%H~%M~%S.%2fβ would display β09~15~23.46β
- tickformatstops
A tuple of
plotly.graph_objects.cone.co lorbar.Tickformatstopinstances or dicts with compatible properties- tickformatstopdefaults
When used in a template (as layout.template.dat a.cone.colorbar.tickformatstopdefaults), sets the default property values to use for elements of cone.colorbar.tickformatstops
- ticklen
Sets the tick length (in px).
- tickmode
Sets the tick mode for this axis. If βautoβ, the number of ticks is set via
nticks. If βlinearβ, the placement of the ticks is determined by a starting positiontick0and a tick stepdtick(βlinearβ is the default value iftick0anddtickare provided). If βarrayβ, the placement of the ticks is set viatickvalsand the tick text isticktext. (βarrayβ is the default value iftickvalsis provided).- tickprefix
Sets a tick label prefix.
- ticks
Determines whether ticks are drawn or not. If ββ, this axisβ ticks are not drawn. If βoutsideβ (βinsideβ), this axisβ are drawn outside (inside) the axis lines.
- ticksuffix
Sets a tick label suffix.
- ticktext
Sets the text displayed at the ticks position via
tickvals. Only has an effect iftickmodeis set to βarrayβ. Used withtickvals.- ticktextsrc
Sets the source reference on Chart Studio Cloud for ticktext .
- tickvals
Sets the values at which ticks on this axis appear. Only has an effect if
tickmodeis set to βarrayβ. Used withticktext.- tickvalssrc
Sets the source reference on Chart Studio Cloud for tickvals .
- tickwidth
Sets the tick width (in px).
- title
plotly.graph_objects.cone.colorbar.Titl einstance or dict with compatible properties- titlefont
Deprecated: Please use cone.colorbar.title.font instead. Sets this color barβs title font. Note that the titleβs font used to be set by the now deprecated
titlefontattribute.- titleside
Deprecated: Please use cone.colorbar.title.side instead. Determines the location of color barβs title with respect to the color bar. Note that the titleβs location used to be set by the now deprecated
titlesideattribute.- x
Sets the x position of the color bar (in plot fraction).
- xanchor
Sets this color barβs horizontal position anchor. This anchor binds the
xposition to the βleftβ, βcenterβ or βrightβ of the color bar.- xpad
Sets the amount of padding (in px) along the x direction.
- y
Sets the y position of the color bar (in plot fraction).
- yanchor
Sets this color barβs vertical position anchor This anchor binds the
yposition to the βtopβ, βmiddleβ or βbottomβ of the color bar.- ypad
Sets the amount of padding (in px) along the y direction.
- Returns
- Return type
-
property
colorscaleΒΆ Sets the colorscale. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example,
[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]. To control the bounds of the colorscale in color space, use`cmin` andcmax. Alternatively,colorscalemay be a palette name string of the following list: Greys,YlGnBu,Greens,YlOrRd,Bluered,RdBu,Reds,Bl ues,Picnic,Rainbow,Portland,Jet,Hot,Blackbody,Earth,Electric,Vi ridis,Cividis.The βcolorscaleβ property is a colorscale and may be specified as:
A list of colors that will be spaced evenly to create the colorscale. Many predefined colorscale lists are included in the sequential, diverging, and cyclical modules in the plotly.colors package.
A list of 2-element lists where the first element is the normalized color level value (starting at 0 and ending at 1), and the second item is a valid color string. (e.g. [[0, βgreenβ], [0.5, βredβ], [1.0, βrgb(0, 0, 255)β]])
- One of the following named colorscales:
- [βaggrnylβ, βagsunsetβ, βalgaeβ, βampβ, βarmyroseβ, βbalanceβ,
βblackbodyβ, βblueredβ, βbluesβ, βblugrnβ, βbluylβ, βbrbgβ, βbrwnylβ, βbugnβ, βbupuβ, βburgβ, βburgylβ, βcividisβ, βcurlβ, βdarkmintβ, βdeepβ, βdeltaβ, βdenseβ, βearthβ, βedgeβ, βelectricβ, βemrldβ, βfallβ, βgeyserβ, βgnbuβ, βgrayβ, βgreensβ, βgreysβ, βhalineβ, βhotβ, βhsvβ, βiceβ, βicefireβ, βinfernoβ, βjetβ, βmagentaβ, βmagmaβ, βmatterβ, βmintβ, βmrybmβ, βmygbmβ, βorangesβ, βorrdβ, βoryelβ, βpeachβ, βphaseβ, βpicnicβ, βpinkylβ, βpiygβ, βplasmaβ, βplotly3β, βportlandβ, βprgnβ, βpubuβ, βpubugnβ, βpuorβ, βpurdβ, βpurpβ, βpurplesβ, βpurporβ, βrainbowβ, βrdbuβ, βrdgyβ, βrdpuβ, βrdylbuβ, βrdylgnβ, βredorβ, βredsβ, βsolarβ, βspectralβ, βspeedβ, βsunsetβ, βsunsetdarkβ, βtealβ, βtealgrnβ, βtealroseβ, βtempoβ, βtempsβ, βthermalβ, βtropicβ, βturbidβ, βtwilightβ, βviridisβ, βylgnβ, βylgnbuβ, βylorbrβ, βylorrdβ].
Appending β_rβ to a named colorscale reverses it.
- Returns
- Return type
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βxβ, βyβ, βzβ, βuβ, βvβ, βwβ, βnormβ, βtextβ, βnameβ] joined with β+β characters (e.g. βx+yβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.cone.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- Returns
- Return type
-
property
hovertemplateΒΆ Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time- formatβs syntax %{variable|d3-time-format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time- format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. variablenormAnything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.- The βhovertemplateβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertemplatesrcΒΆ Sets the source reference on Chart Studio Cloud for hovertemplate .
The βhovertemplatesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hovertextΒΆ Same as
text.- The βhovertextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
lightingΒΆ The βlightingβ property is an instance of Lighting that may be specified as:
An instance of
plotly.graph_objects.cone.LightingA dict of string/value properties that will be passed to the Lighting constructor
Supported dict properties:
- ambient
Ambient light increases overall color visibility but can wash out the image.
- diffuse
Represents the extent that incident rays are reflected in a range of angles.
- facenormalsepsilon
Epsilon for face normals calculation avoids math issues arising from degenerate geometry.
- fresnel
Represents the reflectance as a dependency of the viewing angle; e.g. paper is reflective when viewing it from the edge of the paper (almost 90 degrees), causing shine.
- roughness
Alters specular reflection; the rougher the surface, the wider and less contrasty the shine.
- specular
Represents the level that incident rays are reflected in a single direction, causing shine.
- vertexnormalsepsilon
Epsilon for vertex normals calculation avoids math issues arising from degenerate geometry.
- Returns
- Return type
-
property
lightpositionΒΆ The βlightpositionβ property is an instance of Lightposition that may be specified as:
An instance of
plotly.graph_objects.cone.LightpositionA dict of string/value properties that will be passed to the Lightposition constructor
Supported dict properties:
- x
Numeric vector, representing the X coordinate for each vertex.
- y
Numeric vector, representing the Y coordinate for each vertex.
- z
Numeric vector, representing the Z coordinate for each vertex.
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the surface. Please note that in the case of using high
opacityvalues for example a value greater than or equal to 0.5 on two surfaces (and 0.25 with four surfaces), an overlay of multiple transparent surfaces may not perfectly be sorted in depth by the webgl API. This behavior may be improved in the near future and is subject to change.- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
reversescaleΒΆ Reverses the color mapping if true. If true,
cminwill correspond to the last color in the array andcmaxwill correspond to the first color.The βreversescaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
sceneΒΆ Sets a reference between this traceβs 3D coordinate system and a 3D scene. If βsceneβ (the default value), the (x,y,z) coordinates refer to
layout.scene. If βscene2β, the (x,y,z) coordinates refer tolayout.scene2, and so on.The βsceneβ property is an identifier of a particular subplot, of type βsceneβ, that may be specified as the string βsceneβ optionally followed by an integer >= 1 (e.g. βsceneβ, βscene1β, βscene2β, βscene3β, etc.)
- Returns
- Return type
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
showscaleΒΆ Determines whether or not a colorbar is displayed for this trace.
The βshowscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
sizemodeΒΆ Determines whether
sizerefis set as a βscaledβ (i.e unitless) scalar (normalized by the max u/v/w norm in the vector field) or as βabsoluteβ value (in the same units as the vector field).- The βsizemodeβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βscaledβ, βabsoluteβ]
- Returns
- Return type
Any
-
property
sizerefΒΆ Adjusts the cone size scaling. The size of the cones is determined by their u/v/w norm multiplied a factor and
sizeref. This factor (computed internally) corresponds to the minimum βtimeβ to travel across two successive x/y/z positions at the average velocity of those two successive positions. All cones in a given trace use the same factor. Withsizemodeset to βscaledβ,sizerefis unitless, its default value is 0.5 Withsizemodeset to βabsoluteβ,sizerefhas the same units as the u/v/w vector field, its the default value is half the sampleβs maximum vector norm.- The βsizerefβ property is a number and may be specified as:
An int or float in the interval [0, inf]
- Returns
- Return type
int|float
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.cone.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
textΒΆ Sets the text elements associated with the cones. If trace
hoverinfocontains a βtextβ flag and βhovertextβ is not set, these elements will be seen in the hover labels.- The βtextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
typeΒΆ
-
property
uΒΆ Sets the x components of the vector field.
The βuβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
usrcΒΆ Sets the source reference on Chart Studio Cloud for u .
The βusrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
vΒΆ Sets the y components of the vector field.
The βvβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
vsrcΒΆ Sets the source reference on Chart Studio Cloud for v .
The βvsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
wΒΆ Sets the z components of the vector field.
The βwβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
wsrcΒΆ Sets the source reference on Chart Studio Cloud for w .
The βwsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
xΒΆ Sets the x coordinates of the vector field and of the displayed cones.
The βxβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
xsrcΒΆ Sets the source reference on Chart Studio Cloud for x .
The βxsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
yΒΆ Sets the y coordinates of the vector field and of the displayed cones.
The βyβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
ysrcΒΆ Sets the source reference on Chart Studio Cloud for y .
The βysrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
zΒΆ Sets the z coordinates of the vector field and of the displayed cones.
The βzβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
-
class
plotly.graph_objects.Contour(arg=None, autocolorscale=None, autocontour=None, coloraxis=None, colorbar=None, colorscale=None, connectgaps=None, contours=None, customdata=None, customdatasrc=None, dx=None, dy=None, fillcolor=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hoverongaps=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, legendgroup=None, line=None, meta=None, metasrc=None, name=None, ncontours=None, opacity=None, reversescale=None, showlegend=None, showscale=None, stream=None, text=None, textsrc=None, transpose=None, uid=None, uirevision=None, visible=None, x=None, x0=None, xaxis=None, xcalendar=None, xsrc=None, xtype=None, y=None, y0=None, yaxis=None, ycalendar=None, ysrc=None, ytype=None, z=None, zauto=None, zhoverformat=None, zmax=None, zmid=None, zmin=None, zsrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
autocolorscaleΒΆ Determines whether the colorscale is a default palette (
autocolorscale: true) or the palette determined bycolorscale. In casecolorscaleis unspecified orautocolorscaleis true, the default palette will be chosen according to whether numbers in thecolorarray are all positive, all negative or mixed.The βautocolorscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
autocontourΒΆ Determines whether or not the contour level attributes are picked by an algorithm. If True, the number of contour levels can be set in
ncontours. If False, set the contour level attributes incontours.The βautocontourβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
coloraxisΒΆ Sets a reference to a shared color axis. References to these shared color axes are βcoloraxisβ, βcoloraxis2β, βcoloraxis3β, etc. Settings for these shared color axes are set in the layout, under
layout.coloraxis,layout.coloraxis2, etc. Note that multiple color scales can be linked to the same color axis.The βcoloraxisβ property is an identifier of a particular subplot, of type βcoloraxisβ, that may be specified as the string βcoloraxisβ optionally followed by an integer >= 1 (e.g. βcoloraxisβ, βcoloraxis1β, βcoloraxis2β, βcoloraxis3β, etc.)
- Returns
- Return type
-
property
colorbarΒΆ The βcolorbarβ property is an instance of ColorBar that may be specified as:
An instance of
plotly.graph_objects.contour.ColorBarA dict of string/value properties that will be passed to the ColorBar constructor
Supported dict properties:
- bgcolor
Sets the color of padded area.
- bordercolor
Sets the axis line color.
- borderwidth
Sets the width (in px) or the border enclosing this color bar.
- dtick
Sets the step in-between ticks on this axis. Use with
tick0. Must be a positive number, or special strings available to βlogβ and βdateβ axes. If the axistypeis βlogβ, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, β¦ set dtick to 1. To set tick marks at 1, 100, 10000, β¦ set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, β¦ set dtick to log_10(5), or 0.69897000433. βlogβ has several special values; βL<f>β, wherefis a positive number, gives ticks linearly spaced in value (but not position). For exampletick0= 0.1,dtick= βL0.5β will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use βD1β (all digits) or βD2β (only 2 and 5).tick0is ignored for βD1β and βD2β. If the axistypeis βdateβ, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, setdtickto 86400000.0. βdateβ also has special values βM<n>β gives ticks spaced by a number of months.nmust be a positive integer. To set ticks on the 15th of every third month, settick0to β2000-01-15β anddtickto βM3β. To set ticks every 4 years, setdtickto βM48β- exponentformat
Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If βnoneβ, it appears as 1,000,000,000. If βeβ, 1e+9. If βEβ, 1E+9. If βpowerβ, 1x10^9 (with 9 in a super script). If βSIβ, 1G. If βBβ, 1B.
- len
Sets the length of the color bar This measure excludes the padding of both ends. That is, the color bar length is this length minus the padding on both ends.
- lenmode
Determines whether this color barβs length (i.e. the measure in the color variation direction) is set in units of plot βfractionβ or in *pixels. Use
lento set the value.- nticks
Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to
nticks. Has an effect only iftickmodeis set to βautoβ.- outlinecolor
Sets the axis line color.
- outlinewidth
Sets the width (in px) of the axis line.
- separatethousands
If βtrueβ, even 4-digit integers are separated
- showexponent
If βallβ, all exponents are shown besides their significands. If βfirstβ, only the exponent of the first tick is shown. If βlastβ, only the exponent of the last tick is shown. If βnoneβ, no exponents appear.
- showticklabels
Determines whether or not the tick labels are drawn.
- showtickprefix
If βallβ, all tick labels are displayed with a prefix. If βfirstβ, only the first tick is displayed with a prefix. If βlastβ, only the last tick is displayed with a suffix. If βnoneβ, tick prefixes are hidden.
- showticksuffix
Same as
showtickprefixbut for tick suffixes.- thickness
Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
- thicknessmode
Determines whether this color barβs thickness (i.e. the measure in the constant color direction) is set in units of plot βfractionβ or in βpixelsβ. Use
thicknessto set the value.- tick0
Sets the placement of the first tick on this axis. Use with
dtick. If the axistypeis βlogβ, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set thetick0to 2) except whendtick`=*L<f>* (see `dtickfor more info). If the axistypeis βdateβ, it should be a date string, like date data. If the axistypeis βcategoryβ, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.- tickangle
Sets the angle of the tick labels with respect to the horizontal. For example, a
tickangleof -90 draws the tick labels vertically.- tickcolor
Sets the tick color.
- tickfont
Sets the color barβs tick label font
- tickformat
Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format And for dates see: https://github.com/d3/d3-time- format#locale_format We add one item to d3βs date formatter: β%{n}fβ for fractional seconds with n digits. For example, 2016-10-13 09:15:23.456 with tickformat β%H~%M~%S.%2fβ would display β09~15~23.46β
- tickformatstops
A tuple of
plotly.graph_objects.contour .colorbar.Tickformatstopinstances or dicts with compatible properties- tickformatstopdefaults
When used in a template (as layout.template.dat a.contour.colorbar.tickformatstopdefaults), sets the default property values to use for elements of contour.colorbar.tickformatstops
- ticklen
Sets the tick length (in px).
- tickmode
Sets the tick mode for this axis. If βautoβ, the number of ticks is set via
nticks. If βlinearβ, the placement of the ticks is determined by a starting positiontick0and a tick stepdtick(βlinearβ is the default value iftick0anddtickare provided). If βarrayβ, the placement of the ticks is set viatickvalsand the tick text isticktext. (βarrayβ is the default value iftickvalsis provided).- tickprefix
Sets a tick label prefix.
- ticks
Determines whether ticks are drawn or not. If ββ, this axisβ ticks are not drawn. If βoutsideβ (βinsideβ), this axisβ are drawn outside (inside) the axis lines.
- ticksuffix
Sets a tick label suffix.
- ticktext
Sets the text displayed at the ticks position via
tickvals. Only has an effect iftickmodeis set to βarrayβ. Used withtickvals.- ticktextsrc
Sets the source reference on Chart Studio Cloud for ticktext .
- tickvals
Sets the values at which ticks on this axis appear. Only has an effect if
tickmodeis set to βarrayβ. Used withticktext.- tickvalssrc
Sets the source reference on Chart Studio Cloud for tickvals .
- tickwidth
Sets the tick width (in px).
- title
plotly.graph_objects.contour.colorbar.T itleinstance or dict with compatible properties- titlefont
Deprecated: Please use contour.colorbar.title.font instead. Sets this color barβs title font. Note that the titleβs font used to be set by the now deprecated
titlefontattribute.- titleside
Deprecated: Please use contour.colorbar.title.side instead. Determines the location of color barβs title with respect to the color bar. Note that the titleβs location used to be set by the now deprecated
titlesideattribute.- x
Sets the x position of the color bar (in plot fraction).
- xanchor
Sets this color barβs horizontal position anchor. This anchor binds the
xposition to the βleftβ, βcenterβ or βrightβ of the color bar.- xpad
Sets the amount of padding (in px) along the x direction.
- y
Sets the y position of the color bar (in plot fraction).
- yanchor
Sets this color barβs vertical position anchor This anchor binds the
yposition to the βtopβ, βmiddleβ or βbottomβ of the color bar.- ypad
Sets the amount of padding (in px) along the y direction.
- Returns
- Return type
-
property
colorscaleΒΆ Sets the colorscale. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example,
[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]. To control the bounds of the colorscale in color space, use`zmin` andzmax. Alternatively,colorscalemay be a palette name string of the following list: Greys,YlGnBu,Greens,YlOrRd,Bluered,RdBu,Reds,Bl ues,Picnic,Rainbow,Portland,Jet,Hot,Blackbody,Earth,Electric,Vi ridis,Cividis.The βcolorscaleβ property is a colorscale and may be specified as:
A list of colors that will be spaced evenly to create the colorscale. Many predefined colorscale lists are included in the sequential, diverging, and cyclical modules in the plotly.colors package.
A list of 2-element lists where the first element is the normalized color level value (starting at 0 and ending at 1), and the second item is a valid color string. (e.g. [[0, βgreenβ], [0.5, βredβ], [1.0, βrgb(0, 0, 255)β]])
- One of the following named colorscales:
- [βaggrnylβ, βagsunsetβ, βalgaeβ, βampβ, βarmyroseβ, βbalanceβ,
βblackbodyβ, βblueredβ, βbluesβ, βblugrnβ, βbluylβ, βbrbgβ, βbrwnylβ, βbugnβ, βbupuβ, βburgβ, βburgylβ, βcividisβ, βcurlβ, βdarkmintβ, βdeepβ, βdeltaβ, βdenseβ, βearthβ, βedgeβ, βelectricβ, βemrldβ, βfallβ, βgeyserβ, βgnbuβ, βgrayβ, βgreensβ, βgreysβ, βhalineβ, βhotβ, βhsvβ, βiceβ, βicefireβ, βinfernoβ, βjetβ, βmagentaβ, βmagmaβ, βmatterβ, βmintβ, βmrybmβ, βmygbmβ, βorangesβ, βorrdβ, βoryelβ, βpeachβ, βphaseβ, βpicnicβ, βpinkylβ, βpiygβ, βplasmaβ, βplotly3β, βportlandβ, βprgnβ, βpubuβ, βpubugnβ, βpuorβ, βpurdβ, βpurpβ, βpurplesβ, βpurporβ, βrainbowβ, βrdbuβ, βrdgyβ, βrdpuβ, βrdylbuβ, βrdylgnβ, βredorβ, βredsβ, βsolarβ, βspectralβ, βspeedβ, βsunsetβ, βsunsetdarkβ, βtealβ, βtealgrnβ, βtealroseβ, βtempoβ, βtempsβ, βthermalβ, βtropicβ, βturbidβ, βtwilightβ, βviridisβ, βylgnβ, βylgnbuβ, βylorbrβ, βylorrdβ].
Appending β_rβ to a named colorscale reverses it.
- Returns
- Return type
-
property
connectgapsΒΆ Determines whether or not gaps (i.e. {nan} or missing values) in the
zdata are filled in. It is defaulted to true ifzis a one dimensional array otherwise it is defaulted to false.The βconnectgapsβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
contoursΒΆ The βcontoursβ property is an instance of Contours that may be specified as:
An instance of
plotly.graph_objects.contour.ContoursA dict of string/value properties that will be passed to the Contours constructor
Supported dict properties:
- coloring
Determines the coloring method showing the contour values. If βfillβ, coloring is done evenly between each contour level If βheatmapβ, a heatmap gradient coloring is applied between each contour level. If βlinesβ, coloring is done on the contour lines. If βnoneβ, no coloring is applied on this trace.
- end
Sets the end contour level value. Must be more than
contours.start- labelfont
Sets the font used for labeling the contour levels. The default color comes from the lines, if shown. The default family and size come from
layout.font.- labelformat
Sets the contour label formatting rule using d3 formatting mini-language which is very similar to Python, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format
- operation
Sets the constraint operation. β=β keeps regions equal to
valueβ<β and β<=β keep regions less thanvalueβ>β and β>=β keep regions greater thanvalueβ[]β, β()β, β[)β, and β(]β keep regions insidevalue[0]tovalue[1]β][β, β)(β, β](β, β)[β keep regions outsidevalue[0]to value[1]` Open vs. closed intervals make no difference to constraint display, but all versions are allowed for consistency with filter transforms.- showlabels
Determines whether to label the contour lines with their values.
- showlines
Determines whether or not the contour lines are drawn. Has an effect only if
contours.coloringis set to βfillβ.- size
Sets the step between each contour level. Must be positive.
- start
Sets the starting contour level value. Must be less than
contours.end- type
If
levels, the data is represented as a contour plot with multiple levels displayed. Ifconstraint, the data is represented as constraints with the invalid region shaded as specified by theoperationandvalueparameters.- value
Sets the value or values of the constraint boundary. When
operationis set to one of the comparison values (=,<,>=,>,<=) βvalueβ is expected to be a number. Whenoperationis set to one of the interval values ([],(),[),(],][,)(,](,)[) βvalueβ is expected to be an array of two numbers where the first is the lower bound and the second is the upper bound.
- Returns
- Return type
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
dxΒΆ Sets the x coordinate step. See
x0for more info.- The βdxβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
dyΒΆ Sets the y coordinate step. See
y0for more info.- The βdyβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
fillcolorΒΆ Sets the fill color if
contours.typeis βconstraintβ. Defaults to a half-transparent variant of the line color, marker color, or marker line color, whichever is available.- The βfillcolorβ property is a color and may be specified as:
A hex string (e.g. β#ff0000β)
An rgb/rgba string (e.g. βrgb(255,0,0)β)
An hsl/hsla string (e.g. βhsl(0,100%,50%)β)
An hsv/hsva string (e.g. βhsv(0,100%,100%)β)
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure, beige, bisque, black, blanchedalmond, blue, blueviolet, brown, burlywood, cadetblue, chartreuse, chocolate, coral, cornflowerblue, cornsilk, crimson, cyan, darkblue, darkcyan, darkgoldenrod, darkgray, darkgrey, darkgreen, darkkhaki, darkmagenta, darkolivegreen, darkorange, darkorchid, darkred, darksalmon, darkseagreen, darkslateblue, darkslategray, darkslategrey, darkturquoise, darkviolet, deeppink, deepskyblue, dimgray, dimgrey, dodgerblue, firebrick, floralwhite, forestgreen, fuchsia, gainsboro, ghostwhite, gold, goldenrod, gray, grey, green, greenyellow, honeydew, hotpink, indianred, indigo, ivory, khaki, lavender, lavenderblush, lawngreen, lemonchiffon, lightblue, lightcoral, lightcyan, lightgoldenrodyellow, lightgray, lightgrey, lightgreen, lightpink, lightsalmon, lightseagreen, lightskyblue, lightslategray, lightslategrey, lightsteelblue, lightyellow, lime, limegreen, linen, magenta, maroon, mediumaquamarine, mediumblue, mediumorchid, mediumpurple, mediumseagreen, mediumslateblue, mediumspringgreen, mediumturquoise, mediumvioletred, midnightblue, mintcream, mistyrose, moccasin, navajowhite, navy, oldlace, olive, olivedrab, orange, orangered, orchid, palegoldenrod, palegreen, paleturquoise, palevioletred, papayawhip, peachpuff, peru, pink, plum, powderblue, purple, red, rosybrown, royalblue, rebeccapurple, saddlebrown, salmon, sandybrown, seagreen, seashell, sienna, silver, skyblue, slateblue, slategray, slategrey, snow, springgreen, steelblue, tan, teal, thistle, tomato, turquoise, violet, wheat, white, whitesmoke, yellow, yellowgreen
A number that will be interpreted as a color according to contour.colorscale
- Returns
- Return type
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βxβ, βyβ, βzβ, βtextβ, βnameβ] joined with β+β characters (e.g. βx+yβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.contour.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- Returns
- Return type
-
property
hoverongapsΒΆ Determines whether or not gaps (i.e. {nan} or missing values) in the
zdata have hover labels associated with them.The βhoverongapsβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
hovertemplateΒΆ Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time- formatβs syntax %{variable|d3-time-format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time- format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.- The βhovertemplateβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertemplatesrcΒΆ Sets the source reference on Chart Studio Cloud for hovertemplate .
The βhovertemplatesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hovertextΒΆ Same as
text.The βhovertextβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
lineΒΆ The βlineβ property is an instance of Line that may be specified as:
An instance of
plotly.graph_objects.contour.LineA dict of string/value properties that will be passed to the Line constructor
Supported dict properties:
- color
Sets the color of the contour level. Has no effect if
contours.coloringis set to βlinesβ.- dash
Sets the dash style of lines. Set to a dash type string (βsolidβ, βdotβ, βdashβ, βlongdashβ, βdashdotβ, or βlongdashdotβ) or a dash length list in px (eg β5px,10px,2px,2pxβ).
- smoothing
Sets the amount of smoothing for the contour lines, where 0 corresponds to no smoothing.
- width
Sets the contour line width in (in px) Defaults to 0.5 when
contours.typeis βlevelsβ. Defaults to 2 whencontour.typeis βconstraintβ.
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
ncontoursΒΆ Sets the maximum number of contour levels. The actual number of contours will be chosen automatically to be less than or equal to the value of
ncontours. Has an effect only ifautocontouris True or ifcontours.sizeis missing.- The βncontoursβ property is a integer and may be specified as:
An int (or float that will be cast to an int) in the interval [1, 9223372036854775807]
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the trace.
- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
reversescaleΒΆ Reverses the color mapping if true. If true,
zminwill correspond to the last color in the array andzmaxwill correspond to the first color.The βreversescaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
showscaleΒΆ Determines whether or not a colorbar is displayed for this trace.
The βshowscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.contour.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
textΒΆ Sets the text elements associated with each z value.
The βtextβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
transposeΒΆ Transposes the z data.
The βtransposeβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
xΒΆ Sets the x coordinates.
The βxβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
x0ΒΆ Alternate to
x. Builds a linear space of x coordinates. Use withdxwherex0is the starting coordinate anddxthe step.The βx0β property accepts values of any type
- Returns
- Return type
Any
-
property
xaxisΒΆ Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.The βxaxisβ property is an identifier of a particular subplot, of type βxβ, that may be specified as the string βxβ optionally followed by an integer >= 1 (e.g. βxβ, βx1β, βx2β, βx3β, etc.)
- Returns
- Return type
-
property
xcalendarΒΆ Sets the calendar system to use with
xdate data.- The βxcalendarβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βgregorianβ, βchineseβ, βcopticβ, βdiscworldβ, βethiopianβ, βhebrewβ, βislamicβ, βjulianβ, βmayanβ, βnanakshahiβ, βnepaliβ, βpersianβ, βjalaliβ, βtaiwanβ, βthaiβ, βummalquraβ]
- Returns
- Return type
Any
-
property
xsrcΒΆ Sets the source reference on Chart Studio Cloud for x .
The βxsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
xtypeΒΆ If βarrayβ, the heatmapβs x coordinates are given by βxβ (the default behavior when
xis provided). If βscaledβ, the heatmapβs x coordinates are given by βx0β and βdxβ (the default behavior whenxis not provided).- The βxtypeβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βarrayβ, βscaledβ]
- Returns
- Return type
Any
-
property
yΒΆ Sets the y coordinates.
The βyβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
y0ΒΆ Alternate to
y. Builds a linear space of y coordinates. Use withdywherey0is the starting coordinate anddythe step.The βy0β property accepts values of any type
- Returns
- Return type
Any
-
property
yaxisΒΆ Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.The βyaxisβ property is an identifier of a particular subplot, of type βyβ, that may be specified as the string βyβ optionally followed by an integer >= 1 (e.g. βyβ, βy1β, βy2β, βy3β, etc.)
- Returns
- Return type
-
property
ycalendarΒΆ Sets the calendar system to use with
ydate data.- The βycalendarβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βgregorianβ, βchineseβ, βcopticβ, βdiscworldβ, βethiopianβ, βhebrewβ, βislamicβ, βjulianβ, βmayanβ, βnanakshahiβ, βnepaliβ, βpersianβ, βjalaliβ, βtaiwanβ, βthaiβ, βummalquraβ]
- Returns
- Return type
Any
-
property
ysrcΒΆ Sets the source reference on Chart Studio Cloud for y .
The βysrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
ytypeΒΆ If βarrayβ, the heatmapβs y coordinates are given by βyβ (the default behavior when
yis provided) If βscaledβ, the heatmapβs y coordinates are given by βy0β and βdyβ (the default behavior whenyis not provided)- The βytypeβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βarrayβ, βscaledβ]
- Returns
- Return type
Any
-
property
zΒΆ Sets the z data.
The βzβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
zautoΒΆ Determines whether or not the color domain is computed with respect to the input data (here in
z) or the bounds set inzminandzmaxDefaults tofalsewhenzminandzmaxare set by the user.The βzautoβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
zhoverformatΒΆ Sets the hover text formatting rule using d3 formatting mini- languages which are very similar to those in Python. See: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format
- The βzhoverformatβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
zmaxΒΆ Sets the upper bound of the color domain. Value should have the same units as in
zand if set,zminmust be set as well.- The βzmaxβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zmidΒΆ Sets the mid-point of the color domain by scaling
zminand/orzmaxto be equidistant to this point. Value should have the same units as inz. Has no effect whenzautoisfalse.- The βzmidβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zminΒΆ Sets the lower bound of the color domain. Value should have the same units as in
zand if set,zmaxmust be set as well.- The βzminβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
-
class
plotly.graph_objects.Contourcarpet(arg=None, a=None, a0=None, asrc=None, atype=None, autocolorscale=None, autocontour=None, b=None, b0=None, bsrc=None, btype=None, carpet=None, coloraxis=None, colorbar=None, colorscale=None, contours=None, customdata=None, customdatasrc=None, da=None, db=None, fillcolor=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, legendgroup=None, line=None, meta=None, metasrc=None, name=None, ncontours=None, opacity=None, reversescale=None, showlegend=None, showscale=None, stream=None, text=None, textsrc=None, transpose=None, uid=None, uirevision=None, visible=None, xaxis=None, yaxis=None, z=None, zauto=None, zmax=None, zmid=None, zmin=None, zsrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
aΒΆ Sets the x coordinates.
The βaβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
a0ΒΆ Alternate to
x. Builds a linear space of x coordinates. Use withdxwherex0is the starting coordinate anddxthe step.The βa0β property accepts values of any type
- Returns
- Return type
Any
-
property
asrcΒΆ Sets the source reference on Chart Studio Cloud for a .
The βasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
atypeΒΆ If βarrayβ, the heatmapβs x coordinates are given by βxβ (the default behavior when
xis provided). If βscaledβ, the heatmapβs x coordinates are given by βx0β and βdxβ (the default behavior whenxis not provided).- The βatypeβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βarrayβ, βscaledβ]
- Returns
- Return type
Any
-
property
autocolorscaleΒΆ Determines whether the colorscale is a default palette (
autocolorscale: true) or the palette determined bycolorscale. In casecolorscaleis unspecified orautocolorscaleis true, the default palette will be chosen according to whether numbers in thecolorarray are all positive, all negative or mixed.The βautocolorscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
autocontourΒΆ Determines whether or not the contour level attributes are picked by an algorithm. If True, the number of contour levels can be set in
ncontours. If False, set the contour level attributes incontours.The βautocontourβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
bΒΆ Sets the y coordinates.
The βbβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
b0ΒΆ Alternate to
y. Builds a linear space of y coordinates. Use withdywherey0is the starting coordinate anddythe step.The βb0β property accepts values of any type
- Returns
- Return type
Any
-
property
bsrcΒΆ Sets the source reference on Chart Studio Cloud for b .
The βbsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
btypeΒΆ If βarrayβ, the heatmapβs y coordinates are given by βyβ (the default behavior when
yis provided) If βscaledβ, the heatmapβs y coordinates are given by βy0β and βdyβ (the default behavior whenyis not provided)- The βbtypeβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[βarrayβ, βscaledβ]
- Returns
- Return type
Any
-
property
carpetΒΆ The
carpetof the carpet axes on which this contour trace lies- The βcarpetβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
coloraxisΒΆ Sets a reference to a shared color axis. References to these shared color axes are βcoloraxisβ, βcoloraxis2β, βcoloraxis3β, etc. Settings for these shared color axes are set in the layout, under
layout.coloraxis,layout.coloraxis2, etc. Note that multiple color scales can be linked to the same color axis.The βcoloraxisβ property is an identifier of a particular subplot, of type βcoloraxisβ, that may be specified as the string βcoloraxisβ optionally followed by an integer >= 1 (e.g. βcoloraxisβ, βcoloraxis1β, βcoloraxis2β, βcoloraxis3β, etc.)
- Returns
- Return type
-
property
colorbarΒΆ The βcolorbarβ property is an instance of ColorBar that may be specified as:
An instance of
plotly.graph_objects.contourcarpet.ColorBarA dict of string/value properties that will be passed to the ColorBar constructor
Supported dict properties:
- bgcolor
Sets the color of padded area.
- bordercolor
Sets the axis line color.
- borderwidth
Sets the width (in px) or the border enclosing this color bar.
- dtick
Sets the step in-between ticks on this axis. Use with
tick0. Must be a positive number, or special strings available to βlogβ and βdateβ axes. If the axistypeis βlogβ, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, β¦ set dtick to 1. To set tick marks at 1, 100, 10000, β¦ set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, β¦ set dtick to log_10(5), or 0.69897000433. βlogβ has several special values; βL<f>β, wherefis a positive number, gives ticks linearly spaced in value (but not position). For exampletick0= 0.1,dtick= βL0.5β will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use βD1β (all digits) or βD2β (only 2 and 5).tick0is ignored for βD1β and βD2β. If the axistypeis βdateβ, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, setdtickto 86400000.0. βdateβ also has special values βM<n>β gives ticks spaced by a number of months.nmust be a positive integer. To set ticks on the 15th of every third month, settick0to β2000-01-15β anddtickto βM3β. To set ticks every 4 years, setdtickto βM48β- exponentformat
Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If βnoneβ, it appears as 1,000,000,000. If βeβ, 1e+9. If βEβ, 1E+9. If βpowerβ, 1x10^9 (with 9 in a super script). If βSIβ, 1G. If βBβ, 1B.
- len
Sets the length of the color bar This measure excludes the padding of both ends. That is, the color bar length is this length minus the padding on both ends.
- lenmode
Determines whether this color barβs length (i.e. the measure in the color variation direction) is set in units of plot βfractionβ or in *pixels. Use
lento set the value.- nticks
Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to
nticks. Has an effect only iftickmodeis set to βautoβ.- outlinecolor
Sets the axis line color.
- outlinewidth
Sets the width (in px) of the axis line.
- separatethousands
If βtrueβ, even 4-digit integers are separated
- showexponent
If βallβ, all exponents are shown besides their significands. If βfirstβ, only the exponent of the first tick is shown. If βlastβ, only the exponent of the last tick is shown. If βnoneβ, no exponents appear.
- showticklabels
Determines whether or not the tick labels are drawn.
- showtickprefix
If βallβ, all tick labels are displayed with a prefix. If βfirstβ, only the first tick is displayed with a prefix. If βlastβ, only the last tick is displayed with a suffix. If βnoneβ, tick prefixes are hidden.
- showticksuffix
Same as
showtickprefixbut for tick suffixes.- thickness
Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
- thicknessmode
Determines whether this color barβs thickness (i.e. the measure in the constant color direction) is set in units of plot βfractionβ or in βpixelsβ. Use
thicknessto set the value.- tick0
Sets the placement of the first tick on this axis. Use with
dtick. If the axistypeis βlogβ, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set thetick0to 2) except whendtick`=*L<f>* (see `dtickfor more info). If the axistypeis βdateβ, it should be a date string, like date data. If the axistypeis βcategoryβ, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.- tickangle
Sets the angle of the tick labels with respect to the horizontal. For example, a
tickangleof -90 draws the tick labels vertically.- tickcolor
Sets the tick color.
- tickfont
Sets the color barβs tick label font
- tickformat
Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format And for dates see: https://github.com/d3/d3-time- format#locale_format We add one item to d3βs date formatter: β%{n}fβ for fractional seconds with n digits. For example, 2016-10-13 09:15:23.456 with tickformat β%H~%M~%S.%2fβ would display β09~15~23.46β
- tickformatstops
A tuple of
plotly.graph_objects.contour carpet.colorbar.Tickformatstopinstances or dicts with compatible properties- tickformatstopdefaults
When used in a template (as layout.template.dat a.contourcarpet.colorbar.tickformatstopdefaults ), sets the default property values to use for elements of contourcarpet.colorbar.tickformatstops
- ticklen
Sets the tick length (in px).
- tickmode
Sets the tick mode for this axis. If βautoβ, the number of ticks is set via
nticks. If βlinearβ, the placement of the ticks is determined by a starting positiontick0and a tick stepdtick(βlinearβ is the default value iftick0anddtickare provided). If βarrayβ, the placement of the ticks is set viatickvalsand the tick text isticktext. (βarrayβ is the default value iftickvalsis provided).- tickprefix
Sets a tick label prefix.
- ticks
Determines whether ticks are drawn or not. If ββ, this axisβ ticks are not drawn. If βoutsideβ (βinsideβ), this axisβ are drawn outside (inside) the axis lines.
- ticksuffix
Sets a tick label suffix.
- ticktext
Sets the text displayed at the ticks position via
tickvals. Only has an effect iftickmodeis set to βarrayβ. Used withtickvals.- ticktextsrc
Sets the source reference on Chart Studio Cloud for ticktext .
- tickvals
Sets the values at which ticks on this axis appear. Only has an effect if
tickmodeis set to βarrayβ. Used withticktext.- tickvalssrc
Sets the source reference on Chart Studio Cloud for tickvals .
- tickwidth
Sets the tick width (in px).
- title
plotly.graph_objects.contourcarpet.colo rbar.Titleinstance or dict with compatible properties- titlefont
Deprecated: Please use contourcarpet.colorbar.title.font instead. Sets this color barβs title font. Note that the titleβs font used to be set by the now deprecated
titlefontattribute.- titleside
Deprecated: Please use contourcarpet.colorbar.title.side instead. Determines the location of color barβs title with respect to the color bar. Note that the titleβs location used to be set by the now deprecated
titlesideattribute.- x
Sets the x position of the color bar (in plot fraction).
- xanchor
Sets this color barβs horizontal position anchor. This anchor binds the
xposition to the βleftβ, βcenterβ or βrightβ of the color bar.- xpad
Sets the amount of padding (in px) along the x direction.
- y
Sets the y position of the color bar (in plot fraction).
- yanchor
Sets this color barβs vertical position anchor This anchor binds the
yposition to the βtopβ, βmiddleβ or βbottomβ of the color bar.- ypad
Sets the amount of padding (in px) along the y direction.
- Returns
- Return type
-
property
colorscaleΒΆ Sets the colorscale. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example,
[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]. To control the bounds of the colorscale in color space, use`zmin` andzmax. Alternatively,colorscalemay be a palette name string of the following list: Greys,YlGnBu,Greens,YlOrRd,Bluered,RdBu,Reds,Bl ues,Picnic,Rainbow,Portland,Jet,Hot,Blackbody,Earth,Electric,Vi ridis,Cividis.The βcolorscaleβ property is a colorscale and may be specified as:
A list of colors that will be spaced evenly to create the colorscale. Many predefined colorscale lists are included in the sequential, diverging, and cyclical modules in the plotly.colors package.
A list of 2-element lists where the first element is the normalized color level value (starting at 0 and ending at 1), and the second item is a valid color string. (e.g. [[0, βgreenβ], [0.5, βredβ], [1.0, βrgb(0, 0, 255)β]])
- One of the following named colorscales:
- [βaggrnylβ, βagsunsetβ, βalgaeβ, βampβ, βarmyroseβ, βbalanceβ,
βblackbodyβ, βblueredβ, βbluesβ, βblugrnβ, βbluylβ, βbrbgβ, βbrwnylβ, βbugnβ, βbupuβ, βburgβ, βburgylβ, βcividisβ, βcurlβ, βdarkmintβ, βdeepβ, βdeltaβ, βdenseβ, βearthβ, βedgeβ, βelectricβ, βemrldβ, βfallβ, βgeyserβ, βgnbuβ, βgrayβ, βgreensβ, βgreysβ, βhalineβ, βhotβ, βhsvβ, βiceβ, βicefireβ, βinfernoβ, βjetβ, βmagentaβ, βmagmaβ, βmatterβ, βmintβ, βmrybmβ, βmygbmβ, βorangesβ, βorrdβ, βoryelβ, βpeachβ, βphaseβ, βpicnicβ, βpinkylβ, βpiygβ, βplasmaβ, βplotly3β, βportlandβ, βprgnβ, βpubuβ, βpubugnβ, βpuorβ, βpurdβ, βpurpβ, βpurplesβ, βpurporβ, βrainbowβ, βrdbuβ, βrdgyβ, βrdpuβ, βrdylbuβ, βrdylgnβ, βredorβ, βredsβ, βsolarβ, βspectralβ, βspeedβ, βsunsetβ, βsunsetdarkβ, βtealβ, βtealgrnβ, βtealroseβ, βtempoβ, βtempsβ, βthermalβ, βtropicβ, βturbidβ, βtwilightβ, βviridisβ, βylgnβ, βylgnbuβ, βylorbrβ, βylorrdβ].
Appending β_rβ to a named colorscale reverses it.
- Returns
- Return type
-
property
contoursΒΆ The βcontoursβ property is an instance of Contours that may be specified as:
An instance of
plotly.graph_objects.contourcarpet.ContoursA dict of string/value properties that will be passed to the Contours constructor
Supported dict properties:
- coloring
Determines the coloring method showing the contour values. If βfillβ, coloring is done evenly between each contour level If βlinesβ, coloring is done on the contour lines. If βnoneβ, no coloring is applied on this trace.
- end
Sets the end contour level value. Must be more than
contours.start- labelfont
Sets the font used for labeling the contour levels. The default color comes from the lines, if shown. The default family and size come from
layout.font.- labelformat
Sets the contour label formatting rule using d3 formatting mini-language which is very similar to Python, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format
- operation
Sets the constraint operation. β=β keeps regions equal to
valueβ<β and β<=β keep regions less thanvalueβ>β and β>=β keep regions greater thanvalueβ[]β, β()β, β[)β, and β(]β keep regions insidevalue[0]tovalue[1]β][β, β)(β, β](β, β)[β keep regions outsidevalue[0]to value[1]` Open vs. closed intervals make no difference to constraint display, but all versions are allowed for consistency with filter transforms.- showlabels
Determines whether to label the contour lines with their values.
- showlines
Determines whether or not the contour lines are drawn. Has an effect only if
contours.coloringis set to βfillβ.- size
Sets the step between each contour level. Must be positive.
- start
Sets the starting contour level value. Must be less than
contours.end- type
If
levels, the data is represented as a contour plot with multiple levels displayed. Ifconstraint, the data is represented as constraints with the invalid region shaded as specified by theoperationandvalueparameters.- value
Sets the value or values of the constraint boundary. When
operationis set to one of the comparison values (=,<,>=,>,<=) βvalueβ is expected to be a number. Whenoperationis set to one of the interval values ([],(),[),(],][,)(,](,)[) βvalueβ is expected to be an array of two numbers where the first is the lower bound and the second is the upper bound.
- Returns
- Return type
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
daΒΆ Sets the x coordinate step. See
x0for more info.- The βdaβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
dbΒΆ Sets the y coordinate step. See
y0for more info.- The βdbβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
fillcolorΒΆ Sets the fill color if
contours.typeis βconstraintβ. Defaults to a half-transparent variant of the line color, marker color, or marker line color, whichever is available.- The βfillcolorβ property is a color and may be specified as:
A hex string (e.g. β#ff0000β)
An rgb/rgba string (e.g. βrgb(255,0,0)β)
An hsl/hsla string (e.g. βhsl(0,100%,50%)β)
An hsv/hsva string (e.g. βhsv(0,100%,100%)β)
- A named CSS color:
aliceblue, antiquewhite, aqua, aquamarine, azure, beige, bisque, black, blanchedalmond, blue, blueviolet, brown, burlywood, cadetblue, chartreuse, chocolate, coral, cornflowerblue, cornsilk, crimson, cyan, darkblue, darkcyan, darkgoldenrod, darkgray, darkgrey, darkgreen, darkkhaki, darkmagenta, darkolivegreen, darkorange, darkorchid, darkred, darksalmon, darkseagreen, darkslateblue, darkslategray, darkslategrey, darkturquoise, darkviolet, deeppink, deepskyblue, dimgray, dimgrey, dodgerblue, firebrick, floralwhite, forestgreen, fuchsia, gainsboro, ghostwhite, gold, goldenrod, gray, grey, green, greenyellow, honeydew, hotpink, indianred, indigo, ivory, khaki, lavender, lavenderblush, lawngreen, lemonchiffon, lightblue, lightcoral, lightcyan, lightgoldenrodyellow, lightgray, lightgrey, lightgreen, lightpink, lightsalmon, lightseagreen, lightskyblue, lightslategray, lightslategrey, lightsteelblue, lightyellow, lime, limegreen, linen, magenta, maroon, mediumaquamarine, mediumblue, mediumorchid, mediumpurple, mediumseagreen, mediumslateblue, mediumspringgreen, mediumturquoise, mediumvioletred, midnightblue, mintcream, mistyrose, moccasin, navajowhite, navy, oldlace, olive, olivedrab, orange, orangered, orchid, palegoldenrod, palegreen, paleturquoise, palevioletred, papayawhip, peachpuff, peru, pink, plum, powderblue, purple, red, rosybrown, royalblue, rebeccapurple, saddlebrown, salmon, sandybrown, seagreen, seashell, sienna, silver, skyblue, slateblue, slategray, slategrey, snow, springgreen, steelblue, tan, teal, thistle, tomato, turquoise, violet, wheat, white, whitesmoke, yellow, yellowgreen
A number that will be interpreted as a color according to contourcarpet.colorscale
- Returns
- Return type
-
property
hovertextΒΆ Same as
text.The βhovertextβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
lineΒΆ The βlineβ property is an instance of Line that may be specified as:
An instance of
plotly.graph_objects.contourcarpet.LineA dict of string/value properties that will be passed to the Line constructor
Supported dict properties:
- color
Sets the color of the contour level. Has no effect if
contours.coloringis set to βlinesβ.- dash
Sets the dash style of lines. Set to a dash type string (βsolidβ, βdotβ, βdashβ, βlongdashβ, βdashdotβ, or βlongdashdotβ) or a dash length list in px (eg β5px,10px,2px,2pxβ).
- smoothing
Sets the amount of smoothing for the contour lines, where 0 corresponds to no smoothing.
- width
Sets the contour line width in (in px) Defaults to 0.5 when
contours.typeis βlevelsβ. Defaults to 2 whencontour.typeis βconstraintβ.
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
ncontoursΒΆ Sets the maximum number of contour levels. The actual number of contours will be chosen automatically to be less than or equal to the value of
ncontours. Has an effect only ifautocontouris True or ifcontours.sizeis missing.- The βncontoursβ property is a integer and may be specified as:
An int (or float that will be cast to an int) in the interval [1, 9223372036854775807]
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the trace.
- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
reversescaleΒΆ Reverses the color mapping if true. If true,
zminwill correspond to the last color in the array andzmaxwill correspond to the first color.The βreversescaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
showscaleΒΆ Determines whether or not a colorbar is displayed for this trace.
The βshowscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.contourcarpet.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
textΒΆ Sets the text elements associated with each z value.
The βtextβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
transposeΒΆ Transposes the z data.
The βtransposeβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
xaxisΒΆ Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.The βxaxisβ property is an identifier of a particular subplot, of type βxβ, that may be specified as the string βxβ optionally followed by an integer >= 1 (e.g. βxβ, βx1β, βx2β, βx3β, etc.)
- Returns
- Return type
-
property
yaxisΒΆ Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.The βyaxisβ property is an identifier of a particular subplot, of type βyβ, that may be specified as the string βyβ optionally followed by an integer >= 1 (e.g. βyβ, βy1β, βy2β, βy3β, etc.)
- Returns
- Return type
-
property
zΒΆ Sets the z data.
The βzβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
zautoΒΆ Determines whether or not the color domain is computed with respect to the input data (here in
z) or the bounds set inzminandzmaxDefaults tofalsewhenzminandzmaxare set by the user.The βzautoβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
zmaxΒΆ Sets the upper bound of the color domain. Value should have the same units as in
zand if set,zminmust be set as well.- The βzmaxβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zmidΒΆ Sets the mid-point of the color domain by scaling
zminand/orzmaxto be equidistant to this point. Value should have the same units as inz. Has no effect whenzautoisfalse.- The βzmidβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zminΒΆ Sets the lower bound of the color domain. Value should have the same units as in
zand if set,zmaxmust be set as well.- The βzminβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
-
class
plotly.graph_objects.Contours(*args, **kwargs)ΒΆ Bases:
dictplotly.graph_objects.Contours is deprecated.
- Please replace it with one of the following more specific types
plotly.graph_objects.contour.Contours
plotly.graph_objects.surface.Contours
etc.
-
class
plotly.graph_objects.Data(*args, **kwargs)ΒΆ Bases:
listplotly.graph_objects.Data is deprecated.
- Please replace it with a list or tuple of instances of the following types
plotly.graph_objects.Scatter
plotly.graph_objects.Bar
plotly.graph_objects.Area
plotly.graph_objects.Histogram
etc.
-
class
plotly.graph_objects.Densitymapbox(arg=None, autocolorscale=None, below=None, coloraxis=None, colorbar=None, colorscale=None, customdata=None, customdatasrc=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, lat=None, latsrc=None, legendgroup=None, lon=None, lonsrc=None, meta=None, metasrc=None, name=None, opacity=None, radius=None, radiussrc=None, reversescale=None, showlegend=None, showscale=None, stream=None, subplot=None, text=None, textsrc=None, uid=None, uirevision=None, visible=None, z=None, zauto=None, zmax=None, zmid=None, zmin=None, zsrc=None, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseTraceType-
property
autocolorscaleΒΆ Determines whether the colorscale is a default palette (
autocolorscale: true) or the palette determined bycolorscale. In casecolorscaleis unspecified orautocolorscaleis true, the default palette will be chosen according to whether numbers in thecolorarray are all positive, all negative or mixed.The βautocolorscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
belowΒΆ Determines if the densitymapbox trace will be inserted before the layer with the specified ID. By default, densitymapbox traces are placed below the first layer of type symbol If set to ββ, the layer will be inserted above every existing layer.
- The βbelowβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
coloraxisΒΆ Sets a reference to a shared color axis. References to these shared color axes are βcoloraxisβ, βcoloraxis2β, βcoloraxis3β, etc. Settings for these shared color axes are set in the layout, under
layout.coloraxis,layout.coloraxis2, etc. Note that multiple color scales can be linked to the same color axis.The βcoloraxisβ property is an identifier of a particular subplot, of type βcoloraxisβ, that may be specified as the string βcoloraxisβ optionally followed by an integer >= 1 (e.g. βcoloraxisβ, βcoloraxis1β, βcoloraxis2β, βcoloraxis3β, etc.)
- Returns
- Return type
-
property
colorbarΒΆ The βcolorbarβ property is an instance of ColorBar that may be specified as:
An instance of
plotly.graph_objects.densitymapbox.ColorBarA dict of string/value properties that will be passed to the ColorBar constructor
Supported dict properties:
- bgcolor
Sets the color of padded area.
- bordercolor
Sets the axis line color.
- borderwidth
Sets the width (in px) or the border enclosing this color bar.
- dtick
Sets the step in-between ticks on this axis. Use with
tick0. Must be a positive number, or special strings available to βlogβ and βdateβ axes. If the axistypeis βlogβ, then ticks are set every 10^(n*dtick) where n is the tick number. For example, to set a tick mark at 1, 10, 100, 1000, β¦ set dtick to 1. To set tick marks at 1, 100, 10000, β¦ set dtick to 2. To set tick marks at 1, 5, 25, 125, 625, 3125, β¦ set dtick to log_10(5), or 0.69897000433. βlogβ has several special values; βL<f>β, wherefis a positive number, gives ticks linearly spaced in value (but not position). For exampletick0= 0.1,dtick= βL0.5β will put ticks at 0.1, 0.6, 1.1, 1.6 etc. To show powers of 10 plus small digits between, use βD1β (all digits) or βD2β (only 2 and 5).tick0is ignored for βD1β and βD2β. If the axistypeis βdateβ, then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, setdtickto 86400000.0. βdateβ also has special values βM<n>β gives ticks spaced by a number of months.nmust be a positive integer. To set ticks on the 15th of every third month, settick0to β2000-01-15β anddtickto βM3β. To set ticks every 4 years, setdtickto βM48β- exponentformat
Determines a formatting rule for the tick exponents. For example, consider the number 1,000,000,000. If βnoneβ, it appears as 1,000,000,000. If βeβ, 1e+9. If βEβ, 1E+9. If βpowerβ, 1x10^9 (with 9 in a super script). If βSIβ, 1G. If βBβ, 1B.
- len
Sets the length of the color bar This measure excludes the padding of both ends. That is, the color bar length is this length minus the padding on both ends.
- lenmode
Determines whether this color barβs length (i.e. the measure in the color variation direction) is set in units of plot βfractionβ or in *pixels. Use
lento set the value.- nticks
Specifies the maximum number of ticks for the particular axis. The actual number of ticks will be chosen automatically to be less than or equal to
nticks. Has an effect only iftickmodeis set to βautoβ.- outlinecolor
Sets the axis line color.
- outlinewidth
Sets the width (in px) of the axis line.
- separatethousands
If βtrueβ, even 4-digit integers are separated
- showexponent
If βallβ, all exponents are shown besides their significands. If βfirstβ, only the exponent of the first tick is shown. If βlastβ, only the exponent of the last tick is shown. If βnoneβ, no exponents appear.
- showticklabels
Determines whether or not the tick labels are drawn.
- showtickprefix
If βallβ, all tick labels are displayed with a prefix. If βfirstβ, only the first tick is displayed with a prefix. If βlastβ, only the last tick is displayed with a suffix. If βnoneβ, tick prefixes are hidden.
- showticksuffix
Same as
showtickprefixbut for tick suffixes.- thickness
Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
- thicknessmode
Determines whether this color barβs thickness (i.e. the measure in the constant color direction) is set in units of plot βfractionβ or in βpixelsβ. Use
thicknessto set the value.- tick0
Sets the placement of the first tick on this axis. Use with
dtick. If the axistypeis βlogβ, then you must take the log of your starting tick (e.g. to set the starting tick to 100, set thetick0to 2) except whendtick`=*L<f>* (see `dtickfor more info). If the axistypeis βdateβ, it should be a date string, like date data. If the axistypeis βcategoryβ, it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.- tickangle
Sets the angle of the tick labels with respect to the horizontal. For example, a
tickangleof -90 draws the tick labels vertically.- tickcolor
Sets the tick color.
- tickfont
Sets the color barβs tick label font
- tickformat
Sets the tick label formatting rule using d3 formatting mini-languages which are very similar to those in Python. For numbers, see: https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format And for dates see: https://github.com/d3/d3-time- format#locale_format We add one item to d3βs date formatter: β%{n}fβ for fractional seconds with n digits. For example, 2016-10-13 09:15:23.456 with tickformat β%H~%M~%S.%2fβ would display β09~15~23.46β
- tickformatstops
A tuple of
plotly.graph_objects.density mapbox.colorbar.Tickformatstopinstances or dicts with compatible properties- tickformatstopdefaults
When used in a template (as layout.template.dat a.densitymapbox.colorbar.tickformatstopdefaults ), sets the default property values to use for elements of densitymapbox.colorbar.tickformatstops
- ticklen
Sets the tick length (in px).
- tickmode
Sets the tick mode for this axis. If βautoβ, the number of ticks is set via
nticks. If βlinearβ, the placement of the ticks is determined by a starting positiontick0and a tick stepdtick(βlinearβ is the default value iftick0anddtickare provided). If βarrayβ, the placement of the ticks is set viatickvalsand the tick text isticktext. (βarrayβ is the default value iftickvalsis provided).- tickprefix
Sets a tick label prefix.
- ticks
Determines whether ticks are drawn or not. If ββ, this axisβ ticks are not drawn. If βoutsideβ (βinsideβ), this axisβ are drawn outside (inside) the axis lines.
- ticksuffix
Sets a tick label suffix.
- ticktext
Sets the text displayed at the ticks position via
tickvals. Only has an effect iftickmodeis set to βarrayβ. Used withtickvals.- ticktextsrc
Sets the source reference on Chart Studio Cloud for ticktext .
- tickvals
Sets the values at which ticks on this axis appear. Only has an effect if
tickmodeis set to βarrayβ. Used withticktext.- tickvalssrc
Sets the source reference on Chart Studio Cloud for tickvals .
- tickwidth
Sets the tick width (in px).
- title
plotly.graph_objects.densitymapbox.colo rbar.Titleinstance or dict with compatible properties- titlefont
Deprecated: Please use densitymapbox.colorbar.title.font instead. Sets this color barβs title font. Note that the titleβs font used to be set by the now deprecated
titlefontattribute.- titleside
Deprecated: Please use densitymapbox.colorbar.title.side instead. Determines the location of color barβs title with respect to the color bar. Note that the titleβs location used to be set by the now deprecated
titlesideattribute.- x
Sets the x position of the color bar (in plot fraction).
- xanchor
Sets this color barβs horizontal position anchor. This anchor binds the
xposition to the βleftβ, βcenterβ or βrightβ of the color bar.- xpad
Sets the amount of padding (in px) along the x direction.
- y
Sets the y position of the color bar (in plot fraction).
- yanchor
Sets this color barβs vertical position anchor This anchor binds the
yposition to the βtopβ, βmiddleβ or βbottomβ of the color bar.- ypad
Sets the amount of padding (in px) along the y direction.
- Returns
- Return type
-
property
colorscaleΒΆ Sets the colorscale. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example,
[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]. To control the bounds of the colorscale in color space, use`zmin` andzmax. Alternatively,colorscalemay be a palette name string of the following list: Greys,YlGnBu,Greens,YlOrRd,Bluered,RdBu,Reds,Bl ues,Picnic,Rainbow,Portland,Jet,Hot,Blackbody,Earth,Electric,Vi ridis,Cividis.The βcolorscaleβ property is a colorscale and may be specified as:
A list of colors that will be spaced evenly to create the colorscale. Many predefined colorscale lists are included in the sequential, diverging, and cyclical modules in the plotly.colors package.
A list of 2-element lists where the first element is the normalized color level value (starting at 0 and ending at 1), and the second item is a valid color string. (e.g. [[0, βgreenβ], [0.5, βredβ], [1.0, βrgb(0, 0, 255)β]])
- One of the following named colorscales:
- [βaggrnylβ, βagsunsetβ, βalgaeβ, βampβ, βarmyroseβ, βbalanceβ,
βblackbodyβ, βblueredβ, βbluesβ, βblugrnβ, βbluylβ, βbrbgβ, βbrwnylβ, βbugnβ, βbupuβ, βburgβ, βburgylβ, βcividisβ, βcurlβ, βdarkmintβ, βdeepβ, βdeltaβ, βdenseβ, βearthβ, βedgeβ, βelectricβ, βemrldβ, βfallβ, βgeyserβ, βgnbuβ, βgrayβ, βgreensβ, βgreysβ, βhalineβ, βhotβ, βhsvβ, βiceβ, βicefireβ, βinfernoβ, βjetβ, βmagentaβ, βmagmaβ, βmatterβ, βmintβ, βmrybmβ, βmygbmβ, βorangesβ, βorrdβ, βoryelβ, βpeachβ, βphaseβ, βpicnicβ, βpinkylβ, βpiygβ, βplasmaβ, βplotly3β, βportlandβ, βprgnβ, βpubuβ, βpubugnβ, βpuorβ, βpurdβ, βpurpβ, βpurplesβ, βpurporβ, βrainbowβ, βrdbuβ, βrdgyβ, βrdpuβ, βrdylbuβ, βrdylgnβ, βredorβ, βredsβ, βsolarβ, βspectralβ, βspeedβ, βsunsetβ, βsunsetdarkβ, βtealβ, βtealgrnβ, βtealroseβ, βtempoβ, βtempsβ, βthermalβ, βtropicβ, βturbidβ, βtwilightβ, βviridisβ, βylgnβ, βylgnbuβ, βylorbrβ, βylorrdβ].
Appending β_rβ to a named colorscale reverses it.
- Returns
- Return type
-
property
customdataΒΆ Assigns 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
The βcustomdataβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
customdatasrcΒΆ Sets the source reference on Chart Studio Cloud for customdata .
The βcustomdatasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverinfoΒΆ Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.The βhoverinfoβ property is a flaglist and may be specified as a string containing:
Any combination of [βlonβ, βlatβ, βzβ, βtextβ, βnameβ] joined with β+β characters (e.g. βlon+latβ) OR exactly one of [βallβ, βnoneβ, βskipβ] (e.g. βskipβ)
A list or array of the above
- Returns
- Return type
Any|numpy.ndarray
-
property
hoverinfosrcΒΆ Sets the source reference on Chart Studio Cloud for hoverinfo .
The βhoverinfosrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hoverlabelΒΆ The βhoverlabelβ property is an instance of Hoverlabel that may be specified as:
An instance of
plotly.graph_objects.densitymapbox.HoverlabelA dict of string/value properties that will be passed to the Hoverlabel constructor
Supported dict properties:
- align
Sets the horizontal alignment of the text content within hover label box. Has an effect only if the hover label text spans more two or more lines
- alignsrc
Sets the source reference on Chart Studio Cloud for align .
- bgcolor
Sets the background color of the hover labels for this trace
- bgcolorsrc
Sets the source reference on Chart Studio Cloud for bgcolor .
- bordercolor
Sets the border color of the hover labels for this trace.
- bordercolorsrc
Sets the source reference on Chart Studio Cloud for bordercolor .
- font
Sets the font used in hover labels.
- namelength
Sets the default length (in number of characters) of the trace name in the hover labels for all traces. -1 shows the whole name regardless of length. 0-3 shows the first 0-3 characters, and an integer >3 will show the whole name if it is less than that many characters, but if it is longer, will truncate to
namelength - 3characters and add an ellipsis.- namelengthsrc
Sets the source reference on Chart Studio Cloud for namelength .
- Returns
- Return type
-
property
hovertemplateΒΆ Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time- formatβs syntax %{variable|d3-time-format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time- format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event-data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.- The βhovertemplateβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertemplatesrcΒΆ Sets the source reference on Chart Studio Cloud for hovertemplate .
The βhovertemplatesrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
hovertextΒΆ Sets hover text elements associated with each (lon,lat) pair If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this traceβs (lon,lat) coordinates. To be seen, trace
hoverinfomust contain a βtextβ flag.- The βhovertextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
hovertextsrcΒΆ Sets the source reference on Chart Studio Cloud for hovertext .
The βhovertextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
idsΒΆ Assigns 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.
The βidsβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
idssrcΒΆ Sets the source reference on Chart Studio Cloud for ids .
The βidssrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
latΒΆ Sets the latitude coordinates (in degrees North).
The βlatβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
latsrcΒΆ Sets the source reference on Chart Studio Cloud for lat .
The βlatsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
legendgroupΒΆ Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
- The βlegendgroupβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
lonΒΆ Sets the longitude coordinates (in degrees East).
The βlonβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
lonsrcΒΆ Sets the source reference on Chart Studio Cloud for lon .
The βlonsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
metaΒΆ Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.The βmetaβ property accepts values of any type
- Returns
- Return type
Any|numpy.ndarray
-
property
metasrcΒΆ Sets the source reference on Chart Studio Cloud for meta .
The βmetasrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
nameΒΆ Sets the trace name. The trace name appear as the legend item and on hover.
- The βnameβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
opacityΒΆ Sets the opacity of the trace.
- The βopacityβ property is a number and may be specified as:
An int or float in the interval [0, 1]
- Returns
- Return type
int|float
-
property
radiusΒΆ Sets the radius of influence of one
lon/latpoint in pixels. Increasing the value makes the densitymapbox trace smoother, but less detailed.- The βradiusβ property is a number and may be specified as:
An int or float in the interval [1, inf]
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
int|float|numpy.ndarray
-
property
radiussrcΒΆ Sets the source reference on Chart Studio Cloud for radius .
The βradiussrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
reversescaleΒΆ Reverses the color mapping if true. If true,
zminwill correspond to the last color in the array andzmaxwill correspond to the first color.The βreversescaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
showlegendΒΆ Determines whether or not an item corresponding to this trace is shown in the legend.
The βshowlegendβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
showscaleΒΆ Determines whether or not a colorbar is displayed for this trace.
The βshowscaleβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
streamΒΆ The βstreamβ property is an instance of Stream that may be specified as:
An instance of
plotly.graph_objects.densitymapbox.StreamA dict of string/value properties that will be passed to the Stream constructor
Supported dict properties:
- maxpoints
Sets the maximum number of points to keep on the plots from an incoming stream. If
maxpointsis set to 50, only the newest 50 points will be displayed on the plot.- token
The stream id number links a data trace on a plot with a stream. See https://chart- studio.plotly.com/settings for more details.
- Returns
- Return type
-
property
subplotΒΆ Sets a reference between this traceβs data coordinates and a mapbox subplot. If βmapboxβ (the default value), the data refer to
layout.mapbox. If βmapbox2β, the data refer tolayout.mapbox2, and so on.The βsubplotβ property is an identifier of a particular subplot, of type βmapboxβ, that may be specified as the string βmapboxβ optionally followed by an integer >= 1 (e.g. βmapboxβ, βmapbox1β, βmapbox2β, βmapbox3β, etc.)
- Returns
- Return type
-
property
textΒΆ Sets text elements associated with each (lon,lat) pair If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this traceβs (lon,lat) coordinates. If trace
hoverinfocontains a βtextβ flag and βhovertextβ is not set, these elements will be seen in the hover labels.- The βtextβ property is a string and must be specified as:
A string
A number that will be converted to a string
A tuple, list, or one-dimensional numpy array of the above
- Returns
- Return type
str|numpy.ndarray
-
property
textsrcΒΆ Sets the source reference on Chart Studio Cloud for text .
The βtextsrcβ property must be specified as a string or as a plotly.grid_objs.Column object
- Returns
- Return type
-
property
typeΒΆ
-
property
uidΒΆ Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
- The βuidβ property is a string and must be specified as:
A string
A number that will be converted to a string
- Returns
- Return type
-
property
uirevisionΒΆ Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.The βuirevisionβ property accepts values of any type
- Returns
- Return type
Any
-
property
visibleΒΆ Determines 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).
- The βvisibleβ property is an enumeration that may be specified as:
- One of the following enumeration values:
[True, False, βlegendonlyβ]
- Returns
- Return type
Any
-
property
zΒΆ Sets the pointsβ weight. For example, a value of 10 would be equivalent to having 10 points of weight 1 in the same spot
The βzβ property is an array that may be specified as a tuple, list, numpy array, or pandas Series
- Returns
- Return type
numpy.ndarray
-
property
zautoΒΆ Determines whether or not the color domain is computed with respect to the input data (here in
z) or the bounds set inzminandzmaxDefaults tofalsewhenzminandzmaxare set by the user.The βzautoβ property must be specified as a bool (either True, or False)
- Returns
- Return type
-
property
zmaxΒΆ Sets the upper bound of the color domain. Value should have the same units as in
zand if set,zminmust be set as well.- The βzmaxβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zmidΒΆ Sets the mid-point of the color domain by scaling
zminand/orzmaxto be equidistant to this point. Value should have the same units as inz. Has no effect whenzautoisfalse.- The βzmidβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
zminΒΆ Sets the lower bound of the color domain. Value should have the same units as in
zand if set,zmaxmust be set as well.- The βzminβ property is a number and may be specified as:
An int or float
- Returns
- Return type
int|float
-
property
-
class
plotly.graph_objects.ErrorX(*args, **kwargs)ΒΆ Bases:
dictplotly.graph_objects.ErrorX is deprecated.
- Please replace it with one of the following more specific types
plotly.graph_objects.scatter.ErrorX
plotly.graph_objects.histogram.ErrorX
etc.
-
class
plotly.graph_objects.ErrorY(*args, **kwargs)ΒΆ Bases:
dictplotly.graph_objects.ErrorY is deprecated.
- Please replace it with one of the following more specific types
plotly.graph_objects.scatter.ErrorY
plotly.graph_objects.histogram.ErrorY
etc.
-
class
plotly.graph_objects.ErrorZ(*args, **kwargs)ΒΆ Bases:
dictplotly.graph_objects.ErrorZ is deprecated.
- Please replace it with one of the following more specific types
plotly.graph_objects.scatter3d.ErrorZ
-
class
plotly.graph_objects.Figure(data=None, layout=None, frames=None, skip_invalid=False, **kwargs)ΒΆ Bases:
plotly.basedatatypes.BaseFigure-
add_annotation(arg=None, align=None, arrowcolor=None, arrowhead=None, arrowside=None, arrowsize=None, arrowwidth=None, ax=None, axref=None, ay=None, ayref=None, bgcolor=None, bordercolor=None, borderpad=None, borderwidth=None, captureevents=None, clicktoshow=None, font=None, height=None, hoverlabel=None, hovertext=None, name=None, opacity=None, showarrow=None, standoff=None, startarrowhead=None, startarrowsize=None, startstandoff=None, templateitemname=None, text=None, textangle=None, valign=None, visible=None, width=None, x=None, xanchor=None, xclick=None, xref=None, xshift=None, y=None, yanchor=None, yclick=None, yref=None, yshift=None, row=None, col=None, secondary_y=None, **kwargs)ΒΆ Create and add a new annotation to the figureβs layout
- Parameters
arg β instance of Annotation or dict with compatible properties
align β Sets the horizontal alignment of the
textwithin the box. Has an effect only iftextspans two or more lines (i.e.textcontains one or more <br> HTML tags) or if an explicit width is set to override the text width.arrowcolor β Sets the color of the annotation arrow.
arrowhead β Sets the end annotation arrow head style.
arrowside β Sets the annotation arrow head position.
arrowsize β Sets the size of the end annotation arrow head, relative to
arrowwidth. A value of 1 (default) gives a head about 3x as wide as the line.arrowwidth β Sets the width (in px) of annotation arrow line.
ax β Sets the x component of the arrow tail about the arrow head. If
axrefispixel, a positive (negative) component corresponds to an arrow pointing from right to left (left to right). Ifaxrefis an axis, this is an absolute value on that axis, likex, NOT a relative value.axref β Indicates in what terms the tail of the annotation (ax,ay) is specified. If
pixel,axis a relative offset in pixels fromx. If set to an x axis id (e.g. βxβ or βx2β),axis specified in the same terms as that axis. This is useful for trendline annotations which should continue to indicate the correct trend when zoomed.ay β Sets the y component of the arrow tail about the arrow head. If
ayrefispixel, a positive (negative) component corresponds to an arrow pointing from bottom to top (top to bottom). Ifayrefis an axis, this is an absolute value on that axis, likey, NOT a relative value.ayref β Indicates in what terms the tail of the annotation (ax,ay) is specified. If
pixel,ayis a relative offset in pixels fromy. If set to a y axis id (e.g. βyβ or βy2β),ayis specified in the same terms as that axis. This is useful for trendline annotations which should continue to indicate the correct trend when zoomed.bgcolor β Sets the background color of the annotation.
bordercolor β Sets the color of the border enclosing the annotation
text.borderpad β Sets the padding (in px) between the
textand the enclosing border.borderwidth β Sets the width (in px) of the border enclosing the annotation
text.captureevents β Determines whether the annotation text box captures mouse move and click events, or allows those events to pass through to data points in the plot that may be behind the annotation. By default
captureeventsis False unlesshovertextis provided. If you use the eventplotly_clickannotationwithouthovertextyou must explicitly enablecaptureevents.clicktoshow β Makes this annotation respond to clicks on the plot. If you click a data point that exactly matches the
xandyvalues of this annotation, and it is hidden (visible: false), it will appear. In βonoffβ mode, you must click the same point again to make it disappear, so if you click multiple points, you can show multiple annotations. In βonoutβ mode, a click anywhere else in the plot (on another data point or not) will hide this annotation. If you need to show/hide this annotation in response to differentxoryvalues, you can setxclickand/oryclick. This is useful for example to label the side of a bar. To label markers though,standoffis preferred overxclickandyclick.font β Sets the annotation text font.
height β Sets an explicit height for the text box. null (default) lets the text set the box height. Taller text will be clipped.
hoverlabel β
plotly.graph_objects.layout.annotation.Hoverlab elinstance or dict with compatible propertieshovertext β Sets text to appear when hovering over this annotation. If omitted or blank, no hover label will appear.
name β When used in a template, named items are created in the output figure in addition to any items the figure already has in this array. You can modify these items in the output figure by making your own item with
templateitemnamematching thisnamealongside your modifications (includingvisible: falseorenabled: falseto hide it). Has no effect outside of a template.opacity β Sets the opacity of the annotation (text + arrow).
showarrow β Determines whether or not the annotation is drawn with an arrow. If True,
textis placed near the arrowβs tail. If False,textlines up with thexandyprovided.standoff β Sets a distance, in pixels, to move the end arrowhead away from the position it is pointing at, for example to point at the edge of a marker independent of zoom. Note that this shortens the arrow from the
ax/ayvector, in contrast toxshift/yshiftwhich moves everything by this amount.startarrowhead β Sets the start annotation arrow head style.
startarrowsize β Sets the size of the start annotation arrow head, relative to
arrowwidth. A value of 1 (default) gives a head about 3x as wide as the line.startstandoff β Sets a distance, in pixels, to move the start arrowhead away from the position it is pointing at, for example to point at the edge of a marker independent of zoom. Note that this shortens the arrow from the
ax/ayvector, in contrast toxshift/yshiftwhich moves everything by this amount.templateitemname β Used to refer to a named item in this array in the template. Named items from the template will be created even without a matching item in the input figure, but you can modify one by making an item with
templateitemnamematching itsname, alongside your modifications (includingvisible: falseorenabled: falseto hide it). If there is no template or no matching item, this item will be hidden unless you explicitly show it withvisible: true.text β Sets the text associated with this annotation. Plotly uses a subset of HTML tags to do things like newline (<br>), bold (<b></b>), italics (<i></i>), hyperlinks (<a href=ββ¦β></a>). Tags <em>, <sup>, <sub> <span> are also supported.
textangle β Sets the angle at which the
textis drawn with respect to the horizontal.valign β Sets the vertical alignment of the
textwithin the box. Has an effect only if an explicit height is set to override the text height.visible β Determines whether or not this annotation is visible.
width β Sets an explicit width for the text box. null (default) lets the text set the box width. Wider text will be clipped. There is no automatic wrapping; use <br> to start a new line.
x β Sets the annotationβs x position. If the axis
typeis βlogβ, then you must take the log of your desired range. If the axistypeis βdateβ, it should be date strings, like date data, though Date objects and unix milliseconds will be accepted and converted to strings. If the axistypeis βcategoryβ, it should be numbers, using the scale where each category is assigned a serial number from zero in the order it appears.xanchor β Sets the text boxβs horizontal position anchor This anchor binds the
xposition to the βleftβ, βcenterβ or βrightβ of the annotation. For example, ifxis set to 1,xrefto βpaperβ andxanchorto βrightβ then the right-most portion of the annotation lines up with the right-most edge of the plotting area. If βautoβ, the anchor is equivalent to βcenterβ for data- referenced annotations or if there is an arrow, whereas for paper-referenced with no arrow, the anchor picked corresponds to the closest side.xclick β Toggle this annotation when clicking a data point whose
xvalue isxclickrather than the annotationβsxvalue.xref β Sets the annotationβs x coordinate axis. If set to an x axis id (e.g. βxβ or βx2β), the
xposition refers to an x coordinate If set to βpaperβ, thexposition refers to the distance from the left side of the plotting area in normalized coordinates where 0 (1) corresponds to the left (right) side.xshift β Shifts the position of the whole annotation and arrow to the right (positive) or left (negative) by this many pixels.
y β Sets the annotationβs y position. If the axis
typeis βlogβ, then you must take the log of your desired range. If the axistypeis βdateβ, it should be date strings, like date data, though Date objects and unix milliseconds will be accepted and converted to strings. If the axistypeis βcategoryβ, it should be numbers, using the scale where each category is assigned a serial number from zero in the order it appears.yanchor β Sets the text boxβs vertical position anchor This anchor binds the
yposition to the βtopβ, βmiddleβ or βbottomβ of the annotation. For example, ifyis set to 1,yrefto βpaperβ andyanchorto βtopβ then the top-most portion of the annotation lines up with the top-most edge of the plotting area. If βautoβ, the anchor is equivalent to βmiddleβ for data-referenced annotations or if there is an arrow, whereas for paper- referenced with no arrow, the anchor picked corresponds to the closest side.yclick β Toggle this annotation when clicking a data point whose
yvalue isyclickrather than the annotationβsyvalue.yref β Sets the annotationβs y coordinate axis. If set to an y axis id (e.g. βyβ or βy2β), the
yposition refers to an y coordinate If set to βpaperβ, theyposition refers to the distance from the bottom of the plotting area in normalized coordinates where 0 (1) corresponds to the bottom (top).yshift β Shifts the position of the whole annotation and arrow up (positive) or down (negative) by this many pixels.
row β Subplot row for annotation
col β Subplot column for annotation
secondary_y β Whether to add annotation to secondary y-axis
- Returns
- Return type
-
add_area(customdata=None, customdatasrc=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, ids=None, idssrc=None, legendgroup=None, marker=None, meta=None, metasrc=None, name=None, opacity=None, r=None, rsrc=None, showlegend=None, stream=None, t=None, tsrc=None, uid=None, uirevision=None, visible=None, row=None, col=None, **kwargs)ΒΆ Add a new Area trace
- Parameters
customdata β Assigns 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
customdatasrc β Sets the source reference on Chart Studio Cloud for customdata .
hoverinfo β Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.hoverinfosrc β Sets the source reference on Chart Studio Cloud for hoverinfo .
hoverlabel β
plotly.graph_objects.area.Hoverlabelinstance or dict with compatible propertiesids β Assigns 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.
idssrc β Sets the source reference on Chart Studio Cloud for ids .
legendgroup β Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
marker β
plotly.graph_objects.area.Markerinstance or dict with compatible propertiesmeta β Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.metasrc β Sets the source reference on Chart Studio Cloud for meta .
name β Sets the trace name. The trace name appear as the legend item and on hover.
opacity β Sets the opacity of the trace.
r β Area traces are deprecated! Please switch to the βbarpolarβ trace type. Sets the radial coordinates for legacy polar chart only.
rsrc β Sets the source reference on Chart Studio Cloud for r .
showlegend β Determines whether or not an item corresponding to this trace is shown in the legend.
stream β
plotly.graph_objects.area.Streaminstance or dict with compatible propertiest β Area traces are deprecated! Please switch to the βbarpolarβ trace type. Sets the angular coordinates for legacy polar chart only.
tsrc β Sets the source reference on Chart Studio Cloud for t .
uid β Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
uirevision β Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.visible β Determines 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).
row (int or None (default)) β Subplot row index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotscol (int or None (default)) β Subplot col index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplots
- Returns
- Return type
-
add_bar(alignmentgroup=None, base=None, basesrc=None, cliponaxis=None, constraintext=None, customdata=None, customdatasrc=None, dx=None, dy=None, error_x=None, error_y=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, insidetextanchor=None, insidetextfont=None, legendgroup=None, marker=None, meta=None, metasrc=None, name=None, offset=None, offsetgroup=None, offsetsrc=None, opacity=None, orientation=None, outsidetextfont=None, r=None, rsrc=None, selected=None, selectedpoints=None, showlegend=None, stream=None, t=None, text=None, textangle=None, textfont=None, textposition=None, textpositionsrc=None, textsrc=None, texttemplate=None, texttemplatesrc=None, tsrc=None, uid=None, uirevision=None, unselected=None, visible=None, width=None, widthsrc=None, x=None, x0=None, xaxis=None, xcalendar=None, xsrc=None, y=None, y0=None, yaxis=None, ycalendar=None, ysrc=None, row=None, col=None, secondary_y=None, **kwargs)ΒΆ Add a new Bar trace
The data visualized by the span of the bars is set in
yiforientationis set th βvβ (the default) and the labels are set inx. By settingorientationto βhβ, the roles are interchanged.- Parameters
alignmentgroup β Set several traces linked to the same position axis or matching axes to the same alignmentgroup. This controls whether bars compute their positional range dependently or independently.
base β Sets where the bar base is drawn (in position axis units). In βstackβ or βrelativeβ barmode, traces that set βbaseβ will be excluded and drawn in βoverlayβ mode instead.
basesrc β Sets the source reference on Chart Studio Cloud for base .
cliponaxis β Determines whether the text nodes are clipped about the subplot axes. To show the text nodes above axis lines and tick labels, make sure to set
xaxis.layerandyaxis.layerto below traces.constraintext β Constrain the size of text inside or outside a bar to be no larger than the bar itself.
customdata β Assigns 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
customdatasrc β Sets the source reference on Chart Studio Cloud for customdata .
dx β Sets the x coordinate step. See
x0for more info.dy β Sets the y coordinate step. See
y0for more info.error_x β
plotly.graph_objects.bar.ErrorXinstance or dict with compatible propertieserror_y β
plotly.graph_objects.bar.ErrorYinstance or dict with compatible propertieshoverinfo β Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.hoverinfosrc β Sets the source reference on Chart Studio Cloud for hoverinfo .
hoverlabel β
plotly.graph_objects.bar.Hoverlabelinstance or dict with compatible propertieshovertemplate β Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time-formatβs syntax %{variable|d3-time- format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time-format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event- data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. variablesvalueandlabel. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.hovertemplatesrc β Sets the source reference on Chart Studio Cloud for hovertemplate .
hovertext β Sets hover text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this traceβs (x,y) coordinates. To be seen, trace
hoverinfomust contain a βtextβ flag.hovertextsrc β Sets the source reference on Chart Studio Cloud for hovertext .
ids β Assigns 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.
idssrc β Sets the source reference on Chart Studio Cloud for ids .
insidetextanchor β Determines if texts are kept at center or start/end points in
textpositionβinsideβ mode.insidetextfont β Sets the font used for
textlying inside the bar.legendgroup β Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
marker β
plotly.graph_objects.bar.Markerinstance or dict with compatible propertiesmeta β Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.metasrc β Sets the source reference on Chart Studio Cloud for meta .
name β Sets the trace name. The trace name appear as the legend item and on hover.
offset β Shifts the position where the bar is drawn (in position axis units). In βgroupβ barmode, traces that set βoffsetβ will be excluded and drawn in βoverlayβ mode instead.
offsetgroup β Set several traces linked to the same position axis or matching axes to the same offsetgroup where bars of the same position coordinate will line up.
offsetsrc β Sets the source reference on Chart Studio Cloud for offset .
opacity β Sets the opacity of the trace.
orientation β Sets the orientation of the bars. With βvβ (βhβ), the value of the each bar spans along the vertical (horizontal).
outsidetextfont β Sets the font used for
textlying outside the bar.r β r coordinates in scatter traces are deprecated!Please switch to the βscatterpolarβ trace type.Sets the radial coordinatesfor legacy polar chart only.
rsrc β Sets the source reference on Chart Studio Cloud for r .
selected β
plotly.graph_objects.bar.Selectedinstance or dict with compatible propertiesselectedpoints β Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.showlegend β Determines whether or not an item corresponding to this trace is shown in the legend.
stream β
plotly.graph_objects.bar.Streaminstance or dict with compatible propertiest β t coordinates in scatter traces are deprecated!Please switch to the βscatterpolarβ trace type.Sets the angular coordinatesfor legacy polar chart only.
text β Sets text elements associated with each (x,y) pair. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this traceβs (x,y) coordinates. If trace
hoverinfocontains a βtextβ flag and βhovertextβ is not set, these elements will be seen in the hover labels.textangle β Sets the angle of the tick labels with respect to the bar. For example, a
tickangleof -90 draws the tick labels vertically. With βautoβ the texts may automatically be rotated to fit with the maximum size in bars.textfont β Sets the font used for
text.textposition β Specifies the location of the
text. βinsideβ positionstextinside, next to the bar end (rotated and scaled if needed). βoutsideβ positionstextoutside, next to the bar end (scaled if needed), unless there is another bar stacked on this one, then the text gets pushed inside. βautoβ tries to positiontextinside the bar, but if the bar is too small and no bar is stacked on this one the text is moved outside.textpositionsrc β Sets the source reference on Chart Studio Cloud for textposition .
textsrc β Sets the source reference on Chart Studio Cloud for text .
texttemplate β Template string used for rendering the information text that appear on points. Note that this will override
textinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time-formatβs syntax %{variable|d3-time- format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time-format#locale_format for details on the date formatting syntax. Every attributes that can be specified per-point (the ones that arearrayOk: true) are available. variablesvalueandlabel.texttemplatesrc β Sets the source reference on Chart Studio Cloud for texttemplate .
tsrc β Sets the source reference on Chart Studio Cloud for t .
uid β Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
uirevision β Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.unselected β
plotly.graph_objects.bar.Unselectedinstance or dict with compatible propertiesvisible β Determines 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).
width β Sets the bar width (in position axis units).
widthsrc β Sets the source reference on Chart Studio Cloud for width .
x β Sets the x coordinates.
x0 β Alternate to
x. Builds a linear space of x coordinates. Use withdxwherex0is the starting coordinate anddxthe step.xaxis β Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.xcalendar β Sets the calendar system to use with
xdate data.xsrc β Sets the source reference on Chart Studio Cloud for x .
y β Sets the y coordinates.
y0 β Alternate to
y. Builds a linear space of y coordinates. Use withdywherey0is the starting coordinate anddythe step.yaxis β Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.ycalendar β Sets the calendar system to use with
ydate data.ysrc β Sets the source reference on Chart Studio Cloud for y .
row (int or None (default)) β Subplot row index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotscol (int or None (default)) β Subplot col index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotssecondary_y (boolean or None (default None)) β
If True, associate this trace with the secondary y-axis of the subplot at the specified row and col. Only valid if all of the following conditions are satisfied:
The figure was created using
plotly.subplots.make_subplots.The row and col arguments are not None
The subplot at the specified row and col has type xy (which is the default) and secondary_y True. These properties are specified in the specs argument to make_subplots. See the make_subplots docstring for more info.
- Returns
- Return type
-
add_barpolar(base=None, basesrc=None, customdata=None, customdatasrc=None, dr=None, dtheta=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, legendgroup=None, marker=None, meta=None, metasrc=None, name=None, offset=None, offsetsrc=None, opacity=None, r=None, r0=None, rsrc=None, selected=None, selectedpoints=None, showlegend=None, stream=None, subplot=None, text=None, textsrc=None, theta=None, theta0=None, thetasrc=None, thetaunit=None, uid=None, uirevision=None, unselected=None, visible=None, width=None, widthsrc=None, row=None, col=None, **kwargs)ΒΆ Add a new Barpolar trace
The data visualized by the radial span of the bars is set in
r- Parameters
base β Sets where the bar base is drawn (in radial axis units). In βstackβ barmode, traces that set βbaseβ will be excluded and drawn in βoverlayβ mode instead.
basesrc β Sets the source reference on Chart Studio Cloud for base .
customdata β Assigns 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
customdatasrc β Sets the source reference on Chart Studio Cloud for customdata .
dr β Sets the r coordinate step.
dtheta β Sets the theta coordinate step. By default, the
dthetastep equals the subplotβs period divided by the length of thercoordinates.hoverinfo β Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.hoverinfosrc β Sets the source reference on Chart Studio Cloud for hoverinfo .
hoverlabel β
plotly.graph_objects.barpolar.Hoverlabelinstance or dict with compatible propertieshovertemplate β Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time-formatβs syntax %{variable|d3-time- format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time-format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event- data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.hovertemplatesrc β Sets the source reference on Chart Studio Cloud for hovertemplate .
hovertext β Same as
text.hovertextsrc β Sets the source reference on Chart Studio Cloud for hovertext .
ids β Assigns 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.
idssrc β Sets the source reference on Chart Studio Cloud for ids .
legendgroup β Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
marker β
plotly.graph_objects.barpolar.Markerinstance or dict with compatible propertiesmeta β Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.metasrc β Sets the source reference on Chart Studio Cloud for meta .
name β Sets the trace name. The trace name appear as the legend item and on hover.
offset β Shifts the angular position where the bar is drawn (in βthetatunitβ units).
offsetsrc β Sets the source reference on Chart Studio Cloud for offset .
opacity β Sets the opacity of the trace.
r β Sets the radial coordinates
r0 β Alternate to
r. Builds a linear space of r coordinates. Use withdrwherer0is the starting coordinate anddrthe step.rsrc β Sets the source reference on Chart Studio Cloud for r .
selected β
plotly.graph_objects.barpolar.Selectedinstance or dict with compatible propertiesselectedpoints β Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.showlegend β Determines whether or not an item corresponding to this trace is shown in the legend.
stream β
plotly.graph_objects.barpolar.Streaminstance or dict with compatible propertiessubplot β Sets a reference between this traceβs data coordinates and a polar subplot. If βpolarβ (the default value), the data refer to
layout.polar. If βpolar2β, the data refer tolayout.polar2, and so on.text β Sets hover text elements associated with each bar. If a single string, the same string appears over all bars. If an array of string, the items are mapped in order to the this traceβs coordinates.
textsrc β Sets the source reference on Chart Studio Cloud for text .
theta β Sets the angular coordinates
theta0 β Alternate to
theta. Builds a linear space of theta coordinates. Use withdthetawheretheta0is the starting coordinate anddthetathe step.thetasrc β Sets the source reference on Chart Studio Cloud for theta .
thetaunit β Sets the unit of input βthetaβ values. Has an effect only when on βlinearβ angular axes.
uid β Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
uirevision β Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.unselected β
plotly.graph_objects.barpolar.Unselectedinstance or dict with compatible propertiesvisible β Determines 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).
width β Sets the bar angular width (in βthetaunitβ units).
widthsrc β Sets the source reference on Chart Studio Cloud for width .
row (int or None (default)) β Subplot row index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotscol (int or None (default)) β Subplot col index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplots
- Returns
- Return type
-
add_box(alignmentgroup=None, boxmean=None, boxpoints=None, customdata=None, customdatasrc=None, dx=None, dy=None, fillcolor=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hoveron=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, jitter=None, legendgroup=None, line=None, lowerfence=None, lowerfencesrc=None, marker=None, mean=None, meansrc=None, median=None, mediansrc=None, meta=None, metasrc=None, name=None, notched=None, notchspan=None, notchspansrc=None, notchwidth=None, offsetgroup=None, opacity=None, orientation=None, pointpos=None, q1=None, q1src=None, q3=None, q3src=None, quartilemethod=None, sd=None, sdsrc=None, selected=None, selectedpoints=None, showlegend=None, stream=None, text=None, textsrc=None, uid=None, uirevision=None, unselected=None, upperfence=None, upperfencesrc=None, visible=None, whiskerwidth=None, width=None, x=None, x0=None, xaxis=None, xcalendar=None, xsrc=None, y=None, y0=None, yaxis=None, ycalendar=None, ysrc=None, row=None, col=None, secondary_y=None, **kwargs)ΒΆ Add a new Box trace
Each box spans from quartile 1 (Q1) to quartile 3 (Q3). The second quartile (Q2, i.e. the median) is marked by a line inside the box. The fences grow outward from the boxesβ edges, by default they span +/- 1.5 times the interquartile range (IQR: Q3-Q1), The sample mean and standard deviation as well as notches and the sample, outlier and suspected outliers points can be optionally added to the box plot. The values and positions corresponding to each boxes can be input using two signatures. The first signature expects users to supply the sample values in the
ydata array for vertical boxes (xfor horizontal boxes). By supplying anx(y) array, one box per distinctx(y) value is drawn If nox(y) list is provided, a single box is drawn. In this case, the box is positioned with the tracenameor withx0(y0) if provided. The second signature expects users to supply the boxes corresponding Q1, median and Q3 statistics in theq1,medianandq3data arrays respectively. Other box features relying on statistics namelylowerfence,upperfence,notchspancan be set directly by the users. To have plotly compute them or to show sample points besides the boxes, users can set theydata array for vertical boxes (xfor horizontal boxes) to a 2D array with the outer length corresponding to the number of boxes in the traces and the inner length corresponding the sample size.- Parameters
alignmentgroup β Set several traces linked to the same position axis or matching axes to the same alignmentgroup. This controls whether bars compute their positional range dependently or independently.
boxmean β If True, the mean of the box(es)β underlying distribution is drawn as a dashed line inside the box(es). If βsdβ the standard deviation is also drawn. Defaults to True when
meanis set. Defaults to βsdβ whensdis set Otherwise defaults to False.boxpoints β If βoutliersβ, only the sample points lying outside the whiskers are shown If βsuspectedoutliersβ, the outlier points are shown and points either less than 4*Q1-3*Q3 or greater than 4*Q3-3*Q1 are highlighted (see
outliercolor) If βallβ, all sample points are shown If False, only the box(es) are shown with no sample points Defaults to βsuspectedoutliersβ whenmarker.outliercolorormarker.line.outliercoloris set. Defaults to βallβ under the q1/median/q3 signature. Otherwise defaults to βoutliersβ.customdata β Assigns 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
customdatasrc β Sets the source reference on Chart Studio Cloud for customdata .
dx β Sets the x coordinate step for multi-box traces set using q1/median/q3.
dy β Sets the y coordinate step for multi-box traces set using q1/median/q3.
fillcolor β Sets the fill color. Defaults to a half-transparent variant of the line color, marker color, or marker line color, whichever is available.
hoverinfo β Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.hoverinfosrc β Sets the source reference on Chart Studio Cloud for hoverinfo .
hoverlabel β
plotly.graph_objects.box.Hoverlabelinstance or dict with compatible propertieshoveron β Do the hover effects highlight individual boxes or sample points or both?
hovertemplate β Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time-formatβs syntax %{variable|d3-time- format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time-format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event- data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.hovertemplatesrc β Sets the source reference on Chart Studio Cloud for hovertemplate .
hovertext β Same as
text.hovertextsrc β Sets the source reference on Chart Studio Cloud for hovertext .
ids β Assigns 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.
idssrc β Sets the source reference on Chart Studio Cloud for ids .
jitter β Sets the amount of jitter in the sample points drawn. If 0, the sample points align along the distribution axis. If 1, the sample points are drawn in a random jitter of width equal to the width of the box(es).
legendgroup β Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
line β
plotly.graph_objects.box.Lineinstance or dict with compatible propertieslowerfence β Sets the lower fence values. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. If
lowerfenceis not provided but a sample (inyorx) is set, we compute the lower as the last sample point below 1.5 times the IQR.lowerfencesrc β Sets the source reference on Chart Studio Cloud for lowerfence .
marker β
plotly.graph_objects.box.Markerinstance or dict with compatible propertiesmean β Sets the mean values. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. If
meanis not provided but a sample (inyorx) is set, we compute the mean for each box using the sample values.meansrc β Sets the source reference on Chart Studio Cloud for mean .
median β Sets the median values. There should be as many items as the number of boxes desired.
mediansrc β Sets the source reference on Chart Studio Cloud for median .
meta β Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.metasrc β Sets the source reference on Chart Studio Cloud for meta .
name β Sets the trace name. The trace name appear as the legend item and on hover. For box traces, the name will also be used for the position coordinate, if
xandx0(yandy0if horizontal) are missing and the position axis is categoricalnotched β Determines whether or not notches are drawn. Notches displays a confidence interval around the median. We compute the confidence interval as median +/- 1.57 * IQR / sqrt(N), where IQR is the interquartile range and N is the sample size. If two boxesβ notches do not overlap there is 95% confidence their medians differ. See https://sites.google.com/site/davidsstatistics/home /notched-box-plots for more info. Defaults to False unless
notchwidthornotchspanis set.notchspan β Sets the notch span from the boxesβ
medianvalues. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. Ifnotchspanis not provided but a sample (inyorx) is set, we compute it as 1.57 * IQR / sqrt(N), where N is the sample size.notchspansrc β Sets the source reference on Chart Studio Cloud for notchspan .
notchwidth β Sets the width of the notches relative to the boxβ width. For example, with 0, the notches are as wide as the box(es).
offsetgroup β Set several traces linked to the same position axis or matching axes to the same offsetgroup where bars of the same position coordinate will line up.
opacity β Sets the opacity of the trace.
orientation β Sets the orientation of the box(es). If βvβ (βhβ), the distribution is visualized along the vertical (horizontal).
pointpos β Sets the position of the sample points in relation to the box(es). If 0, the sample points are places over the center of the box(es). Positive (negative) values correspond to positions to the right (left) for vertical boxes and above (below) for horizontal boxes
q1 β Sets the Quartile 1 values. There should be as many items as the number of boxes desired.
q1src β Sets the source reference on Chart Studio Cloud for q1 .
q3 β Sets the Quartile 3 values. There should be as many items as the number of boxes desired.
q3src β Sets the source reference on Chart Studio Cloud for q3 .
quartilemethod β Sets the method used to compute the sampleβs Q1 and Q3 quartiles. The βlinearβ method uses the 25th percentile for Q1 and 75th percentile for Q3 as computed using method #10 (listed on http://www.amstat.org/publication s/jse/v14n3/langford.html). The βexclusiveβ method uses the median to divide the ordered dataset into two halves if the sample is odd, it does not include the median in either half - Q1 is then the median of the lower half and Q3 the median of the upper half. The βinclusiveβ method also uses the median to divide the ordered dataset into two halves but if the sample is odd, it includes the median in both halves - Q1 is then the median of the lower half and Q3 the median of the upper half.
sd β Sets the standard deviation values. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. If
sdis not provided but a sample (inyorx) is set, we compute the standard deviation for each box using the sample values.sdsrc β Sets the source reference on Chart Studio Cloud for sd .
selected β
plotly.graph_objects.box.Selectedinstance or dict with compatible propertiesselectedpoints β Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.showlegend β Determines whether or not an item corresponding to this trace is shown in the legend.
stream β
plotly.graph_objects.box.Streaminstance or dict with compatible propertiestext β Sets the text elements associated with each sample value. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to the this traceβs (x,y) coordinates. To be seen, trace
hoverinfomust contain a βtextβ flag.textsrc β Sets the source reference on Chart Studio Cloud for text .
uid β Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
uirevision β Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.unselected β
plotly.graph_objects.box.Unselectedinstance or dict with compatible propertiesupperfence β Sets the upper fence values. There should be as many items as the number of boxes desired. This attribute has effect only under the q1/median/q3 signature. If
upperfenceis not provided but a sample (inyorx) is set, we compute the lower as the last sample point above 1.5 times the IQR.upperfencesrc β Sets the source reference on Chart Studio Cloud for upperfence .
visible β Determines 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).
whiskerwidth β Sets the width of the whiskers relative to the boxβ width. For example, with 1, the whiskers are as wide as the box(es).
width β Sets the width of the box in data coordinate If 0 (default value) the width is automatically selected based on the positions of other box traces in the same subplot.
x β Sets the x sample data or coordinates. See overview for more info.
x0 β Sets the x coordinate for single-box traces or the starting coordinate for multi-box traces set using q1/median/q3. See overview for more info.
xaxis β Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.xcalendar β Sets the calendar system to use with
xdate data.xsrc β Sets the source reference on Chart Studio Cloud for x .
y β Sets the y sample data or coordinates. See overview for more info.
y0 β Sets the y coordinate for single-box traces or the starting coordinate for multi-box traces set using q1/median/q3. See overview for more info.
yaxis β Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.ycalendar β Sets the calendar system to use with
ydate data.ysrc β Sets the source reference on Chart Studio Cloud for y .
row (int or None (default)) β Subplot row index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotscol (int or None (default)) β Subplot col index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotssecondary_y (boolean or None (default None)) β
If True, associate this trace with the secondary y-axis of the subplot at the specified row and col. Only valid if all of the following conditions are satisfied:
The figure was created using
plotly.subplots.make_subplots.The row and col arguments are not None
The subplot at the specified row and col has type xy (which is the default) and secondary_y True. These properties are specified in the specs argument to make_subplots. See the make_subplots docstring for more info.
- Returns
- Return type
-
add_candlestick(close=None, closesrc=None, customdata=None, customdatasrc=None, decreasing=None, high=None, highsrc=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, increasing=None, legendgroup=None, line=None, low=None, lowsrc=None, meta=None, metasrc=None, name=None, opacity=None, open=None, opensrc=None, selectedpoints=None, showlegend=None, stream=None, text=None, textsrc=None, uid=None, uirevision=None, visible=None, whiskerwidth=None, x=None, xaxis=None, xcalendar=None, xsrc=None, yaxis=None, row=None, col=None, secondary_y=None, **kwargs)ΒΆ Add a new Candlestick trace
The candlestick is a style of financial chart describing open, high, low and close for a given
xcoordinate (most likely time). The boxes represent the spread between theopenandclosevalues and the lines represent the spread between thelowandhighvalues Sample points where the close value is higher (lower) then the open value are called increasing (decreasing). By default, increasing candles are drawn in green whereas decreasing are drawn in red.- Parameters
close β Sets the close values.
closesrc β Sets the source reference on Chart Studio Cloud for close .
customdata β Assigns 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
customdatasrc β Sets the source reference on Chart Studio Cloud for customdata .
decreasing β
plotly.graph_objects.candlestick.Decreasinginstance or dict with compatible propertieshigh β Sets the high values.
highsrc β Sets the source reference on Chart Studio Cloud for high .
hoverinfo β Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.hoverinfosrc β Sets the source reference on Chart Studio Cloud for hoverinfo .
hoverlabel β
plotly.graph_objects.candlestick.Hoverlabelinstance or dict with compatible propertieshovertext β Same as
text.hovertextsrc β Sets the source reference on Chart Studio Cloud for hovertext .
ids β Assigns 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.
idssrc β Sets the source reference on Chart Studio Cloud for ids .
increasing β
plotly.graph_objects.candlestick.Increasinginstance or dict with compatible propertieslegendgroup β Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
line β
plotly.graph_objects.candlestick.Lineinstance or dict with compatible propertieslow β Sets the low values.
lowsrc β Sets the source reference on Chart Studio Cloud for low .
meta β Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.metasrc β Sets the source reference on Chart Studio Cloud for meta .
name β Sets the trace name. The trace name appear as the legend item and on hover.
opacity β Sets the opacity of the trace.
open β Sets the open values.
opensrc β Sets the source reference on Chart Studio Cloud for open .
selectedpoints β Array containing integer indices of selected points. Has an effect only for traces that support selections. Note that an empty array means an empty selection where the
unselectedare turned on for all points, whereas, any other non-array values means no selection all where theselectedandunselectedstyles have no effect.showlegend β Determines whether or not an item corresponding to this trace is shown in the legend.
stream β
plotly.graph_objects.candlestick.Streaminstance or dict with compatible propertiestext β Sets hover text elements associated with each sample point. If a single string, the same string appears over all the data points. If an array of string, the items are mapped in order to this traceβs sample points.
textsrc β Sets the source reference on Chart Studio Cloud for text .
uid β Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
uirevision β Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.visible β Determines 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).
whiskerwidth β Sets the width of the whiskers relative to the boxβ width. For example, with 1, the whiskers are as wide as the box(es).
x β Sets the x coordinates. If absent, linear coordinate will be generated.
xaxis β Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.xcalendar β Sets the calendar system to use with
xdate data.xsrc β Sets the source reference on Chart Studio Cloud for x .
yaxis β Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.row (int or None (default)) β Subplot row index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotscol (int or None (default)) β Subplot col index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotssecondary_y (boolean or None (default None)) β
If True, associate this trace with the secondary y-axis of the subplot at the specified row and col. Only valid if all of the following conditions are satisfied:
The figure was created using
plotly.subplots.make_subplots.The row and col arguments are not None
The subplot at the specified row and col has type xy (which is the default) and secondary_y True. These properties are specified in the specs argument to make_subplots. See the make_subplots docstring for more info.
- Returns
- Return type
-
add_carpet(a=None, a0=None, aaxis=None, asrc=None, b=None, b0=None, baxis=None, bsrc=None, carpet=None, cheaterslope=None, color=None, customdata=None, customdatasrc=None, da=None, db=None, font=None, ids=None, idssrc=None, meta=None, metasrc=None, name=None, opacity=None, stream=None, uid=None, uirevision=None, visible=None, x=None, xaxis=None, xsrc=None, y=None, yaxis=None, ysrc=None, row=None, col=None, secondary_y=None, **kwargs)ΒΆ Add a new Carpet trace
The data describing carpet axis layout is set in
yand (optionally) alsox. If onlyyis present,xthe plot is interpreted as a cheater plot and is filled in using theyvalues.xandymay either be 2D arrays matching with each dimension matching that ofaandb, or they may be 1D arrays with total length equal to that ofaandb.- Parameters
a β An array containing values of the first parameter value
a0 β Alternate to
a. Builds a linear space of a coordinates. Use withdawherea0is the starting coordinate anddathe step.aaxis β
plotly.graph_objects.carpet.Aaxisinstance or dict with compatible propertiesasrc β Sets the source reference on Chart Studio Cloud for a .
b β A two dimensional array of y coordinates at each carpet point.
b0 β Alternate to
b. Builds a linear space of a coordinates. Use withdbwhereb0is the starting coordinate anddbthe step.baxis β
plotly.graph_objects.carpet.Baxisinstance or dict with compatible propertiesbsrc β Sets the source reference on Chart Studio Cloud for b .
carpet β An identifier for this carpet, so that
scattercarpetandcontourcarpettraces can specify a carpet plot on which they liecheaterslope β The shift applied to each successive row of data in creating a cheater plot. Only used if
xis been ommitted.color β Sets default for all colors associated with this axis all at once: line, font, tick, and grid colors. Grid color is lightened by blending this with the plot background Individual pieces can override this.
customdata β Assigns 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
customdatasrc β Sets the source reference on Chart Studio Cloud for customdata .
da β Sets the a coordinate step. See
a0for more info.db β Sets the b coordinate step. See
b0for more info.font β The default font used for axis & tick labels on this carpet
ids β Assigns 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.
idssrc β Sets the source reference on Chart Studio Cloud for ids .
meta β Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use%{meta[i]}whereiis the index or key of themetaitem in question. To access tracemetain layout attributes, use%{data[n[.meta[i]}whereiis the index or key of themetaandnis the trace index.metasrc β Sets the source reference on Chart Studio Cloud for meta .
name β Sets the trace name. The trace name appear as the legend item and on hover.
opacity β Sets the opacity of the trace.
stream β
plotly.graph_objects.carpet.Streaminstance or dict with compatible propertiesuid β Assign an id to this trace, Use this to provide object constancy between traces during animations and transitions.
uirevision β Controls persistence of some user-driven changes to the trace:
constraintrangeinparcoordstraces, as well as someeditable: truemodifications such asnameandcolorbar.title. Defaults tolayout.uirevision. Note that other user-driven trace attribute changes are controlled bylayoutattributes:trace.visibleis controlled bylayout.legend.uirevision,selectedpointsis controlled bylayout.selectionrevision, andcolorbar.(x|y)(accessible withconfig: {editable: true}) is controlled bylayout.editrevision. Trace changes are tracked byuid, which only falls back on trace index if nouidis provided. So if your app can add/remove traces before the end of thedataarray, such that the same trace has a different index, you can still preserve user-driven changes if you give each trace auidthat stays with it as it moves.visible β Determines 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).
x β A two dimensional array of x coordinates at each carpet point. If ommitted, the plot is a cheater plot and the xaxis is hidden by default.
xaxis β Sets a reference between this traceβs x coordinates and a 2D cartesian x axis. If βxβ (the default value), the x coordinates refer to
layout.xaxis. If βx2β, the x coordinates refer tolayout.xaxis2, and so on.xsrc β Sets the source reference on Chart Studio Cloud for x .
y β A two dimensional array of y coordinates at each carpet point.
yaxis β Sets a reference between this traceβs y coordinates and a 2D cartesian y axis. If βyβ (the default value), the y coordinates refer to
layout.yaxis. If βy2β, the y coordinates refer tolayout.yaxis2, and so on.ysrc β Sets the source reference on Chart Studio Cloud for y .
row (int or None (default)) β Subplot row index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotscol (int or None (default)) β Subplot col index (starting from 1) for the trace to be added. Only valid if figure was created using
plotly.tools.make_subplotssecondary_y (boolean or None (default None)) β
If True, associate this trace with the secondary y-axis of the subplot at the specified row and col. Only valid if all of the following conditions are satisfied:
The figure was created using
plotly.subplots.make_subplots.The row and col arguments are not None
The subplot at the specified row and col has type xy (which is the default) and secondary_y True. These properties are specified in the specs argument to make_subplots. See the make_subplots docstring for more info.
- Returns
- Return type
-
add_choropleth(autocolorscale=None, coloraxis=None, colorbar=None, colorscale=None, customdata=None, customdatasrc=None, featureidkey=None, geo=None, geojson=None, hoverinfo=None, hoverinfosrc=None, hoverlabel=None, hovertemplate=None, hovertemplatesrc=None, hovertext=None, hovertextsrc=None, ids=None, idssrc=None, legendgroup=None, locationmode=None, locations=None, locationssrc=None, marker=None, meta=None, metasrc=None, name=None, reversescale=None, selected=None, selectedpoints=None, showlegend=None, showscale=None, stream=None, text=None, textsrc=None, uid=None, uirevision=None, unselected=None, visible=None, z=None, zauto=None, zmax=None, zmid=None, zmin=None, zsrc=None, row=None, col=None, **kwargs)ΒΆ Add a new Choropleth trace
The data that describes the choropleth value-to-color mapping is set in
z. The geographic locations corresponding to each value inzare set inlocations.- Parameters
autocolorscale β Determines whether the colorscale is a default palette (
autocolorscale: true) or the palette determined bycolorscale. In casecolorscaleis unspecified orautocolorscaleis true, the default palette will be chosen according to whether numbers in thecolorarray are all positive, all negative or mixed.coloraxis β Sets a reference to a shared color axis. References to these shared color axes are βcoloraxisβ, βcoloraxis2β, βcoloraxis3β, etc. Settings for these shared color axes are set in the layout, under
layout.coloraxis,layout.coloraxis2, etc. Note that multiple color scales can be linked to the same color axis.colorbar β
plotly.graph_objects.choropleth.ColorBarinstance or dict with compatible propertiescolorscale β Sets the colorscale. The colorscale must be an array containing arrays mapping a normalized value to an rgb, rgba, hex, hsl, hsv, or named color string. At minimum, a mapping for the lowest (0) and highest (1) values are required. For example,
[[0, 'rgb(0,0,255)'], [1, 'rgb(255,0,0)']]. To control the bounds of the colorscale in color space, use`zmin` andzmax. Alternatively,colorscalemay be a palette name string of the following list: Greys,YlGnBu,Greens,YlOrR d,Bluered,RdBu,Reds,Blues,Picnic,Rainbow,Portland,Jet,H ot,Blackbody,Earth,Electric,Viridis,Cividis.customdata β Assigns 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
customdatasrc β Sets the source reference on Chart Studio Cloud for customdata .
featureidkey β Sets the key in GeoJSON features which is used as id to match the items included in the
locationsarray. Only has an effect whengeojsonis set. Support nested property, for example βproperties.nameβ.geo β Sets a reference between this traceβs geospatial coordinates and a geographic map. If βgeoβ (the default value), the geospatial coordinates refer to
layout.geo. If βgeo2β, the geospatial coordinates refer tolayout.geo2, and so on.geojson β Sets optional GeoJSON data associated with this trace. If not given, the features on the base map are used. It can be set as a valid GeoJSON object or as a URL string. Note that we only accept GeoJSONs of type βFeatureCollectionβ or βFeatureβ with geometries of type βPolygonβ or βMultiPolygonβ.
hoverinfo β Determines which trace information appear on hover. If
noneorskipare set, no information is displayed upon hovering. But, ifnoneis set, click and hover events are still fired.hoverinfosrc β Sets the source reference on Chart Studio Cloud for hoverinfo .
hoverlabel β
plotly.graph_objects.choropleth.Hoverlabelinstance or dict with compatible propertieshovertemplate β Template string used for rendering the information that appear on hover box. Note that this will override
hoverinfo. Variables are inserted using %{variable}, for example βy: %{y}β. Numbers are formatted using d3-formatβs syntax %{variable:d3-format}, for example βPrice: %{y:$.2f}β. https://github.com/d3/d3-3.x-api- reference/blob/master/Formatting.md#d3_format for details on the formatting syntax. Dates are formatted using d3-time-formatβs syntax %{variable|d3-time- format}, for example βDay: %{2019-01-01|%A}β. https://github.com/d3/d3-time-format#locale_format for details on the date formatting syntax. The variables available inhovertemplateare the ones emitted as event data described at this link https://plotly.com/javascript/plotlyjs-events/#event- data. Additionally, every attributes that can be specified per-point (the ones that arearrayOk: true) are available. Anything contained in tag<extra>is displayed in the secondary box, for example β<extra>{fullData.name}</extra>β. To hide the secondary box completely, use an empty tag<extra></extra>.hovertemplatesrc β Sets the source reference on Chart Studio Cloud for hovertemplate .
hovertext β Same as
text.hovertextsrc β Sets the source reference on Chart Studio Cloud for hovertext .
ids β Assigns 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.
idssrc β Sets the source reference on Chart Studio Cloud for ids .
legendgroup β Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
locationmode β Determines the set of locations used to match entries in
locationsto regions on the map. Values βISO-3β, βUSA-statesβ, country names correspond to features on the base map and value βgeojson-idβ corresponds to features from a custom GeoJSON linked to thegeojsonattribute.locations β Sets the coordinates via location IDs or names. See
locationmodefor more info.locationssrc β Sets the source reference on Chart Studio Cloud for locations .
marker β
plotly.graph_objects.choropleth.Markerinstance or dict with compatible propertiesmeta β Assigns extra meta information associated with this trace that can be used in various text attributes. Attributes such as trace
name, graph, axis and colorbartitle.text, annotationtextrangeselector,updatemenuesandsliderslabeltext all supportmeta. To access the tracemetavalues in an attribute in the same trace, simply use
-
