Show Sidebar Hide Sidebar

python figure reference

plotly charts are described declaratively with objects in plotly.graph_objs and dict. Every aspect of a plotly chart (the colors, the grids, the data, and so on) has a corresponding key-value attribute in these objects. This page contains an extensive list of these attributes.

Plotly's graph description places attributes into two categories: traces (objects that describe a single series of data in a graph like Scatter or Heatmap) and layout attributes that apply to the rest of the chart, like the title, xaxis, or annotations).

Here is a simple example of a plotly chart inlined with links to each attribute's reference section.

import plotly
import plotly.plotly as py
import plotly.graph_objs as go

print plotly.__version__                # At least 1.8.6 is required. Upgrade with: $ pip install plotly --upgrade

data = [
    go.Scatter(                         # all "scatter" attributes: https://plot.ly/python/reference/#scatter
        x=[1, 2, 3],                    # more about "x":  /python/reference/#scatter-x
        y=[3, 1, 6],                    # more about "y":  /python/reference/#scatter-y
        marker=dict(                    # marker is an dict, marker keys: /python/reference/#scatter-marker
            color="rgb(16, 32, 77)"     # more about marker's "color": /python/reference/#scatter-marker-color
        )
    ),
    go.Bar(                         # all "bar" chart attributes: /python/reference/#bar
        x=[1, 2, 3],                # more about "x": /python/reference/#bar-x
        y=[3, 1, 6],                # /python/reference/#bar-y
        name="bar chart example"    # /python/reference/#bar-name
    )
]

layout = go.Layout(             # all "layout" attributes: /python/reference/#layout
    title="simple example",     # more about "layout's" "title": /python/reference/#layout-title
    xaxis=dict(                 # all "layout's" "xaxis" attributes: /python/reference/#layout-xaxis
        title="time"            # more about "layout's" "xaxis's" "title": /python/reference/#layout-xaxis-title
    ),
    annotations=[
        dict(                            # all "annotation" attributes: /python/reference/#layout-annotations
            text="simple annotation",    # /python/reference/#layout-annotations-text
            x=0,                         # /python/reference/#layout-annotations-x
            xref="paper",                # /python/reference/#layout-annotations-xref
            y=0,                         # /python/reference/#layout-annotations-y
            yref="paper"                 # /python/reference/#layout-annotations-yref
        )
    ]
)

figure = go.Figure(data=data, layout=layout)

py.plot(figure, filename='api-docs/reference-graph')


scatter

import plotly.graph_objs as go
go.Scatter
A Scatter trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "x", "y", "z", "text", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "x", "y", "x+y", "x+y+z", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • x (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the x coordinates.
  • x0 (number or categorical coordinate string)
    default: 0
    Alternate to `x`. Builds a linear space of x coordinates. Use with `dx` where `x0` is the starting coordinate and `dx` the step.
  • dx (number)
    default: 1
    Sets the x coordinate step. See `x0` for more info.
  • y (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the y coordinates.
  • y0 (number or categorical coordinate string)
    default: 0
    Alternate to `y`. Builds a linear space of y coordinates. Use with `dy` where `y0` is the starting coordinate and `dy` the step.
  • customdata (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Assigns extra data to each scatter point DOM element
  • dy (number)
    default: 1
    Sets the y coordinate step. See `y0` for more info.
  • ids (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    A list of keys for object constancy of data points during animation
  • text (string)
    default: ""
    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 `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
  • hovertext (string)
    default: ""
    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 `hoverinfo` must contain a "text" flag.
  • mode (flaglist string)
    Any combination of "lines", "markers", "text" joined with a "+" OR "none".
    examples: "lines", "markers", "lines+markers", "lines+markers+text", "none"
    Determines the drawing mode for this scatter trace. If the provided `mode` includes "text" then the `text` elements appear at the coordinates. Otherwise, the `text` elements appear on hover. If there are less than 20 points, then the default is "lines+markers". Otherwise, "lines".
  • hoveron (flaglist string)
    Any combination of "points", "fills" joined with a "+"
    examples: "points", "fills", "points+fills"
    Do the hover effects highlight individual points (markers or line points) or do they highlight filled regions? If the fill is "toself" or "tonext" and there are no markers or text, then the default is "fills", otherwise it is "points".
  • line
    • color (color)
      Sets the line color.
    • width (number greater than or equal to 0)
      default: 2
      Sets the line width (in px).
    • shape (enumerated: "linear" | "spline" | "hv" | "vh" | "hvh" | "vhv" )
      default: "linear"
      Determines the line shape. With "spline" the lines are drawn using spline interpolation. The other available values correspond to step-wise line shapes.
    • smoothing (number between or equal to 0 and 1.3)
      default: 1
      Has an effect only if `shape` is set to "spline" Sets the amount of smoothing. "0" corresponds to no smoothing (equivalent to a "linear" shape).
    • dash (string)
      default: "solid"
      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").
    • simplify (boolean)
      default: True
      Simplifies lines by removing nearly-collinear points. When transitioning lines, it may be desirable to disable this so that the number of points along the resulting SVG path is unaffected.
  • connectgaps (boolean)
    Determines whether or not gaps (i.e. {nan} or missing values) in the provided data arrays are connected.
  • fill (enumerated: "none" | "tozeroy" | "tozerox" | "tonexty" | "tonextx" | "toself" | "tonext" )
    default: "none"
    Sets the area to fill with a solid color. Use with `fillcolor` if not "none". "tozerox" and "tozeroy" fill to x=0 and y=0 respectively. "tonextx" and "tonexty" fill between the endpoints of this trace and the endpoints of the trace before it, connecting those endpoints with straight lines (to make a stacked area graph); if there is no trace before it, they behave like "tozerox" and "tozeroy". "toself" connects the endpoints of the trace (or each segment of the trace if it has gaps) into a closed shape. "tonext" fills the space between two traces if one completely encloses the other (eg consecutive contour lines), and behaves like "toself" if there is no trace before it. "tonext" should not be used if one trace does not enclose the other.
  • fillcolor (color)
    Sets the fill color. Defaults to a half-transparent variant of the line color, marker color, or marker line color, whichever is available.
  • marker
    • symbol (enumerated: "0" | "circle" | "100" | "circle-open" | "200" | "circle-dot" | "300" | "circle-open-dot" | "1" | "square" | "101" | "square-open" | "201" | "square-dot" | "301" | "square-open-dot" | "2" | "diamond" | "102" | "diamond-open" | "202" | "diamond-dot" | "302" | "diamond-open-dot" | "3" | "cross" | "103" | "cross-open" | "203" | "cross-dot" | "303" | "cross-open-dot" | "4" | "x" | "104" | "x-open" | "204" | "x-dot" | "304" | "x-open-dot" | "5" | "triangle-up" | "105" | "triangle-up-open" | "205" | "triangle-up-dot" | "305" | "triangle-up-open-dot" | "6" | "triangle-down" | "106" | "triangle-down-open" | "206" | "triangle-down-dot" | "306" | "triangle-down-open-dot" | "7" | "triangle-left" | "107" | "triangle-left-open" | "207" | "triangle-left-dot" | "307" | "triangle-left-open-dot" | "8" | "triangle-right" | "108" | "triangle-right-open" | "208" | "triangle-right-dot" | "308" | "triangle-right-open-dot" | "9" | "triangle-ne" | "109" | "triangle-ne-open" | "209" | "triangle-ne-dot" | "309" | "triangle-ne-open-dot" | "10" | "triangle-se" | "110" | "triangle-se-open" | "210" | "triangle-se-dot" | "310" | "triangle-se-open-dot" | "11" | "triangle-sw" | "111" | "triangle-sw-open" | "211" | "triangle-sw-dot" | "311" | "triangle-sw-open-dot" | "12" | "triangle-nw" | "112" | "triangle-nw-open" | "212" | "triangle-nw-dot" | "312" | "triangle-nw-open-dot" | "13" | "pentagon" | "113" | "pentagon-open" | "213" | "pentagon-dot" | "313" | "pentagon-open-dot" | "14" | "hexagon" | "114" | "hexagon-open" | "214" | "hexagon-dot" | "314" | "hexagon-open-dot" | "15" | "hexagon2" | "115" | "hexagon2-open" | "215" | "hexagon2-dot" | "315" | "hexagon2-open-dot" | "16" | "octagon" | "116" | "octagon-open" | "216" | "octagon-dot" | "316" | "octagon-open-dot" | "17" | "star" | "117" | "star-open" | "217" | "star-dot" | "317" | "star-open-dot" | "18" | "hexagram" | "118" | "hexagram-open" | "218" | "hexagram-dot" | "318" | "hexagram-open-dot" | "19" | "star-triangle-up" | "119" | "star-triangle-up-open" | "219" | "star-triangle-up-dot" | "319" | "star-triangle-up-open-dot" | "20" | "star-triangle-down" | "120" | "star-triangle-down-open" | "220" | "star-triangle-down-dot" | "320" | "star-triangle-down-open-dot" | "21" | "star-square" | "121" | "star-square-open" | "221" | "star-square-dot" | "321" | "star-square-open-dot" | "22" | "star-diamond" | "122" | "star-diamond-open" | "222" | "star-diamond-dot" | "322" | "star-diamond-open-dot" | "23" | "diamond-tall" | "123" | "diamond-tall-open" | "223" | "diamond-tall-dot" | "323" | "diamond-tall-open-dot" | "24" | "diamond-wide" | "124" | "diamond-wide-open" | "224" | "diamond-wide-dot" | "324" | "diamond-wide-open-dot" | "25" | "hourglass" | "125" | "hourglass-open" | "26" | "bowtie" | "126" | "bowtie-open" | "27" | "circle-cross" | "127" | "circle-cross-open" | "28" | "circle-x" | "128" | "circle-x-open" | "29" | "square-cross" | "129" | "square-cross-open" | "30" | "square-x" | "130" | "square-x-open" | "31" | "diamond-cross" | "131" | "diamond-cross-open" | "32" | "diamond-x" | "132" | "diamond-x-open" | "33" | "cross-thin" | "133" | "cross-thin-open" | "34" | "x-thin" | "134" | "x-thin-open" | "35" | "asterisk" | "135" | "asterisk-open" | "36" | "hash" | "136" | "hash-open" | "236" | "hash-dot" | "336" | "hash-open-dot" | "37" | "y-up" | "137" | "y-up-open" | "38" | "y-down" | "138" | "y-down-open" | "39" | "y-left" | "139" | "y-left-open" | "40" | "y-right" | "140" | "y-right-open" | "41" | "line-ew" | "141" | "line-ew-open" | "42" | "line-ns" | "142" | "line-ns-open" | "43" | "line-ne" | "143" | "line-ne-open" | "44" | "line-nw" | "144" | "line-nw-open" )
      default: "circle"
      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.
    • opacity (number between or equal to 0 and 1)
      Sets the marker opacity.
    • size (number greater than or equal to 0)
      default: 6
      Sets the marker size (in px).
    • maxdisplayed (number greater than or equal to 0)
      default: 0
      Sets a maximum number of points to be drawn on the graph. "0" corresponds to no limit.
    • sizeref (number)
      default: 1
      Has an effect only if `marker.size` is set to a numerical array. Sets the scale factor used to determine the rendered size of marker points. Use with `sizemin` and `sizemode`.
    • sizemin (number greater than or equal to 0)
      default: 0
      Has an effect only if `marker.size` is set to a numerical array. Sets the minimum size (in px) of the rendered marker points.
    • sizemode (enumerated: "diameter" | "area" )
      default: "diameter"
      Has an effect only if `marker.size` is set to a numerical array. Sets the rule for which the data in `size` is converted to pixels.
    • showscale (boolean)
      Has an effect only if `marker.color` is set to a numerical array. Determines whether or not a colorbar is displayed.
    • colorbar
      • thicknessmode (enumerated: "fraction" | "pixels" )
        default: "pixels"
        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 `thickness` to set the value.
      • thickness (number greater than or equal to 0)
        default: 30
        Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
      • lenmode (enumerated: "fraction" | "pixels" )
        default: "fraction"
        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 `len` to set the value.
      • len (number greater than or equal to 0)
        default: 1
        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.
      • x (number between or equal to -2 and 3)
        default: 1.02
        Sets the x position of the color bar (in plot fraction).
      • xanchor (enumerated: "left" | "center" | "right" )
        default: "left"
        Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the "left", "center" or "right" of the color bar.
      • xpad (number greater than or equal to 0)
        default: 10
        Sets the amount of padding (in px) along the x direction.
      • y (number between or equal to -2 and 3)
        default: 0.5
        Sets the y position of the color bar (in plot fraction).
      • yanchor (enumerated: "top" | "middle" | "bottom" )
        default: "middle"
        Sets this color bar's vertical position anchor This anchor binds the `y` position to the "top", "middle" or "bottom" of the color bar.
      • ypad (number greater than or equal to 0)
        default: 10
        Sets the amount of padding (in px) along the y direction.
      • outlinecolor (color)
        default: "#444"
        Sets the axis line color.
      • outlinewidth (number greater than or equal to 0)
        default: 1
        Sets the width (in px) of the axis line.
      • bordercolor (color)
        default: "#444"
        Sets the axis line color.
      • borderwidth (number greater than or equal to 0)
        default: 0
        Sets the width (in px) or the border enclosing this color bar.
      • bgcolor (color)
        default: "rgba(0,0,0,0)"
        Sets the color of padded area.
      • tickmode (enumerated: "auto" | "linear" | "array" )
        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 position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. ("array" is the default value if `tickvals` is provided).
      • nticks (integer greater than or equal to 0)
        default: 0
        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 if `tickmode` is set to "auto".
      • tick0 (number or categorical coordinate string)
        Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
      • dtick (number or categorical coordinate string)
        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 axis `type` is "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>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 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). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
      • tickvals (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
        Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `ticktext`.
      • ticktext (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
        Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to "array". Used with `tickvals`.
      • ticks (enumerated: "outside" | "inside" | "" )
        default: ""
        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.
      • ticklen (number greater than or equal to 0)
        default: 5
        Sets the tick length (in px).
      • tickwidth (number greater than or equal to 0)
        default: 1
        Sets the tick width (in px).
      • tickcolor (color)
        default: "#444"
        Sets the tick color.
      • showticklabels (boolean)
        default: True
        Determines whether or not the tick labels are drawn.
      • tickfont
        Sets the tick font.
        • family (string)
          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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
        • color (color)
      • tickangle (angle)
        default: auto
        Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
      • tickformat (string)
        default: ""
        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-format/blob/master/README.md#locale_format And for dates see: https://github.com/d3/d3-time-format/blob/master/README.md#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"
      • tickprefix (string)
        default: ""
        Sets a tick label prefix.
      • showtickprefix (enumerated: "all" | "first" | "last" | "none" )
        default: "all"
        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.
      • ticksuffix (string)
        default: ""
        Sets a tick label suffix.
      • showticksuffix (enumerated: "all" | "first" | "last" | "none" )
        default: "all"
        Same as `showtickprefix` but for tick suffixes.
      • separatethousands (boolean)
        If "True", even 4-digit integers are separated
      • exponentformat (enumerated: "none" | "e" | "E" | "power" | "SI" | "B" )
        default: "B"
        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.
      • showexponent (enumerated: "all" | "first" | "last" | "none" )
        default: "all"
        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.
      • title (string)
        default: "Click to enter colorscale title"
        Sets the title of the color bar.
      • titlefont
        Sets this color bar's title font.
        • family (string)
          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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
        • color (color)
      • titleside (enumerated: "right" | "top" | "bottom" )
        default: "top"
        Determines the location of the colorbar title with respect to the color bar.
      • tickvalssrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for tickvals . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's tickvals data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
      • ticktextsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for ticktext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's ticktext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • line
      • width (number greater than or equal to 0)
        Sets the width (in px) of the lines bounding the marker points.
      • color (color)
        Sets the marker.line color. 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 `cmin` and `cmax` if set.
      • colorscale (colorscale)
        Sets the colorscale and only has an effect if `marker.line.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.line.cmin` and `marker.line.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Greys, YlGnBu, Greens, YlOrRd, Bluered, RdBu, Reds, Blues, Picnic, Rainbow, Portland, Jet, Hot, Blackbody, Earth, Electric, Viridis
      • cauto (boolean)
        default: True
        Has an effect only if `marker.line.color` is set to a numerical array and `cmin`, `cmax` are set by the user. In this case, it controls whether the range of colors in `colorscale` is mapped to the range of values in the `color` array (`cauto: True`), or the `cmin`/`cmax` values (`cauto: False`). Defaults to `False` when `cmin`, `cmax` are set by the user.
      • cmax (number)
        Has an effect only if `marker.line.color` is set to a numerical array. Sets the upper bound of the color domain. Value should be associated to the `marker.line.color` array index, and if set, `marker.line.cmin` must be set as well.
      • cmin (number)
        Has an effect only if `marker.line.color` is set to a numerical array. Sets the lower bound of the color domain. Value should be associated to the `marker.line.color` array index, and if set, `marker.line.cmax` must be set as well.
      • autocolorscale (boolean)
        default: True
        Has an effect only if `marker.line.color` is set to a numerical array. Determines whether the colorscale is a default palette (`autocolorscale: True`) or the palette determined by `marker.line.colorscale`. In case `colorscale` is unspecified or `autocolorscale` is True, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
      • reversescale (boolean)
        Has an effect only if `marker.line.color` is set to a numerical array. Reverses the color mapping if True (`cmin` will correspond to the last color in the array and `cmax` will correspond to the first color).
      • widthsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for width . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's width data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
      • colorsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • color (color)
      Sets the marker color. 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 `cmin` and `cmax` if set.
    • colorscale (colorscale)
      Sets the colorscale and only has an effect if `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` and `marker.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Greys, YlGnBu, Greens, YlOrRd, Bluered, RdBu, Reds, Blues, Picnic, Rainbow, Portland, Jet, Hot, Blackbody, Earth, Electric, Viridis
    • cauto (boolean)
      default: True
      Has an effect only if `marker.color` is set to a numerical array and `cmin`, `cmax` are set by the user. In this case, it controls whether the range of colors in `colorscale` is mapped to the range of values in the `color` array (`cauto: True`), or the `cmin`/`cmax` values (`cauto: False`). Defaults to `False` when `cmin`, `cmax` are set by the user.
    • cmax (number)
      Has an effect only if `marker.color` is set to a numerical array. Sets the upper bound of the color domain. Value should be associated to the `marker.color` array index, and if set, `marker.cmin` must be set as well.
    • cmin (number)
      Has an effect only if `marker.color` is set to a numerical array. Sets the lower bound of the color domain. Value should be associated to the `marker.color` array index, and if set, `marker.cmax` must be set as well.
    • autocolorscale (boolean)
      default: True
      Has an effect only if `marker.color` is set to a numerical array. Determines whether the colorscale is a default palette (`autocolorscale: True`) or the palette determined by `marker.colorscale`. In case `colorscale` is unspecified or `autocolorscale` is True, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
    • reversescale (boolean)
      Has an effect only if `marker.color` is set to a numerical array. Reverses the color mapping if True (`cmin` will correspond to the last color in the array and `cmax` will correspond to the first color).
    • symbolsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for symbol . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's symbol data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • opacitysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for opacity . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's opacity data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • sizesrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for size . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's size data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • colorsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textposition (enumerated: "top left" | "top center" | "top right" | "middle left" | "middle center" | "middle right" | "bottom left" | "bottom center" | "bottom right" )
    default: "middle center"
    Sets the positions of the `text` elements with respects to the (x,y) coordinates.
  • textfont
    Sets the text font.
    • family (string)
    • size (number greater than or equal to 1)
    • color (color)
    • familysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for family . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's family data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • sizesrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for size . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's size data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • colorsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • r (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    For polar chart only.Sets the radial coordinates.
  • t (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    For polar chart only.Sets the angular coordinates.
  • error_y
    • visible (boolean)
      Determines whether or not this set of error bars is visible.
    • type (enumerated: "percent" | "constant" | "sqrt" | "data" )
      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 in `value`. If "sqrt", the bar lengths correspond to the sqaure of the underlying data. If "array", the bar lengths are set with data set `array`.
    • symmetric (boolean)
      Determines whether or not the error bars have the same length in both direction (top/bottom for vertical bars, left/right for horizontal bars.
    • array (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the data corresponding the length of each error bar. Values are plotted relative to the underlying data.
    • arrayminus (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      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.
    • value (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars.
    • valueminus (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars in the bottom (left) direction for vertical (horizontal) bars
    • traceref (integer greater than or equal to 0)
      default: 0
    • tracerefminus (integer greater than or equal to 0)
      default: 0
    • copy_ystyle (boolean)
    • copy_zstyle (boolean)
    • color (color)
      Sets the stoke color of the error bars.
    • thickness (number greater than or equal to 0)
      default: 2
      Sets the thickness (in px) of the error bars.
    • width (number greater than or equal to 0)
      Sets the width (in px) of the cross-bar at both ends of the error bars.
    • arraysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for array . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's array data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • arrayminussrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for arrayminus . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's arrayminus data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • error_x
    • visible (boolean)
      Determines whether or not this set of error bars is visible.
    • type (enumerated: "percent" | "constant" | "sqrt" | "data" )
      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 in `value`. If "sqrt", the bar lengths correspond to the sqaure of the underlying data. If "array", the bar lengths are set with data set `array`.
    • symmetric (boolean)
      Determines whether or not the error bars have the same length in both direction (top/bottom for vertical bars, left/right for horizontal bars.
    • array (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the data corresponding the length of each error bar. Values are plotted relative to the underlying data.
    • arrayminus (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      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.
    • value (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars.
    • valueminus (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars in the bottom (left) direction for vertical (horizontal) bars
    • traceref (integer greater than or equal to 0)
      default: 0
    • tracerefminus (integer greater than or equal to 0)
      default: 0
    • copy_ystyle (boolean)
    • copy_zstyle (boolean)
    • color (color)
      Sets the stoke color of the error bars.
    • thickness (number greater than or equal to 0)
      default: 2
      Sets the thickness (in px) of the error bars.
    • width (number greater than or equal to 0)
      Sets the width (in px) of the cross-bar at both ends of the error bars.
    • arraysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for array . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's array data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • arrayminussrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for arrayminus . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's arrayminus data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xaxis (subplotid)
    default: x
    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 to `layout.xaxis2`, and so on.
  • yaxis (subplotid)
    default: y
    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 to `layout.xaxis2`, and so on.
  • xcalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `x` date data.
  • ycalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `y` date data.
  • xsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for x . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's x data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • ysrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for y . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's y data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • customdatasrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for customdata . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's customdata data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • idssrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for ids . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's ids data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for text . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's text data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • hovertextsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for hovertext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's hovertext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textpositionsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for textposition . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's textposition data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • rsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for r . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's r data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • tsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for t . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's t data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.

box

import plotly.graph_objs as go
go.Box
A Box trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "x", "y", "z", "text", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "x", "y", "x+y", "x+y+z", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • y (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the y sample data or coordinates. See overview for more info.
  • x (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the x sample data or coordinates. See overview for more info.
  • x0 (number or categorical coordinate string)
    Sets the x coordinate of the box. See overview for more info.
  • y0 (number or categorical coordinate string)
    Sets the y coordinate of the box. See overview for more info.
  • whiskerwidth (number between or equal to 0 and 1)
    default: 0.5
    Sets the width of the whiskers relative to the box' width. For example, with 1, the whiskers are as wide as the box(es).
  • boxpoints (enumerated: "all" | "outliers" | "suspectedoutliers" | False )
    default: "outliers"
    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
  • boxmean (enumerated: True | "sd" | False )
    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.
  • jitter (number between or equal to 0 and 1)
    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).
  • pointpos (number between or equal to -2 and 2)
    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
  • orientation (enumerated: "v" | "h" )
    Sets the orientation of the box(es). If "v" ("h"), the distribution is visualized along the vertical (horizontal).
  • marker
    • outliercolor (color)
      default: "rgba(0, 0, 0, 0)"
      Sets the color of the outlier sample points.
    • symbol (enumerated: "0" | "circle" | "100" | "circle-open" | "200" | "circle-dot" | "300" | "circle-open-dot" | "1" | "square" | "101" | "square-open" | "201" | "square-dot" | "301" | "square-open-dot" | "2" | "diamond" | "102" | "diamond-open" | "202" | "diamond-dot" | "302" | "diamond-open-dot" | "3" | "cross" | "103" | "cross-open" | "203" | "cross-dot" | "303" | "cross-open-dot" | "4" | "x" | "104" | "x-open" | "204" | "x-dot" | "304" | "x-open-dot" | "5" | "triangle-up" | "105" | "triangle-up-open" | "205" | "triangle-up-dot" | "305" | "triangle-up-open-dot" | "6" | "triangle-down" | "106" | "triangle-down-open" | "206" | "triangle-down-dot" | "306" | "triangle-down-open-dot" | "7" | "triangle-left" | "107" | "triangle-left-open" | "207" | "triangle-left-dot" | "307" | "triangle-left-open-dot" | "8" | "triangle-right" | "108" | "triangle-right-open" | "208" | "triangle-right-dot" | "308" | "triangle-right-open-dot" | "9" | "triangle-ne" | "109" | "triangle-ne-open" | "209" | "triangle-ne-dot" | "309" | "triangle-ne-open-dot" | "10" | "triangle-se" | "110" | "triangle-se-open" | "210" | "triangle-se-dot" | "310" | "triangle-se-open-dot" | "11" | "triangle-sw" | "111" | "triangle-sw-open" | "211" | "triangle-sw-dot" | "311" | "triangle-sw-open-dot" | "12" | "triangle-nw" | "112" | "triangle-nw-open" | "212" | "triangle-nw-dot" | "312" | "triangle-nw-open-dot" | "13" | "pentagon" | "113" | "pentagon-open" | "213" | "pentagon-dot" | "313" | "pentagon-open-dot" | "14" | "hexagon" | "114" | "hexagon-open" | "214" | "hexagon-dot" | "314" | "hexagon-open-dot" | "15" | "hexagon2" | "115" | "hexagon2-open" | "215" | "hexagon2-dot" | "315" | "hexagon2-open-dot" | "16" | "octagon" | "116" | "octagon-open" | "216" | "octagon-dot" | "316" | "octagon-open-dot" | "17" | "star" | "117" | "star-open" | "217" | "star-dot" | "317" | "star-open-dot" | "18" | "hexagram" | "118" | "hexagram-open" | "218" | "hexagram-dot" | "318" | "hexagram-open-dot" | "19" | "star-triangle-up" | "119" | "star-triangle-up-open" | "219" | "star-triangle-up-dot" | "319" | "star-triangle-up-open-dot" | "20" | "star-triangle-down" | "120" | "star-triangle-down-open" | "220" | "star-triangle-down-dot" | "320" | "star-triangle-down-open-dot" | "21" | "star-square" | "121" | "star-square-open" | "221" | "star-square-dot" | "321" | "star-square-open-dot" | "22" | "star-diamond" | "122" | "star-diamond-open" | "222" | "star-diamond-dot" | "322" | "star-diamond-open-dot" | "23" | "diamond-tall" | "123" | "diamond-tall-open" | "223" | "diamond-tall-dot" | "323" | "diamond-tall-open-dot" | "24" | "diamond-wide" | "124" | "diamond-wide-open" | "224" | "diamond-wide-dot" | "324" | "diamond-wide-open-dot" | "25" | "hourglass" | "125" | "hourglass-open" | "26" | "bowtie" | "126" | "bowtie-open" | "27" | "circle-cross" | "127" | "circle-cross-open" | "28" | "circle-x" | "128" | "circle-x-open" | "29" | "square-cross" | "129" | "square-cross-open" | "30" | "square-x" | "130" | "square-x-open" | "31" | "diamond-cross" | "131" | "diamond-cross-open" | "32" | "diamond-x" | "132" | "diamond-x-open" | "33" | "cross-thin" | "133" | "cross-thin-open" | "34" | "x-thin" | "134" | "x-thin-open" | "35" | "asterisk" | "135" | "asterisk-open" | "36" | "hash" | "136" | "hash-open" | "236" | "hash-dot" | "336" | "hash-open-dot" | "37" | "y-up" | "137" | "y-up-open" | "38" | "y-down" | "138" | "y-down-open" | "39" | "y-left" | "139" | "y-left-open" | "40" | "y-right" | "140" | "y-right-open" | "41" | "line-ew" | "141" | "line-ew-open" | "42" | "line-ns" | "142" | "line-ns-open" | "43" | "line-ne" | "143" | "line-ne-open" | "44" | "line-nw" | "144" | "line-nw-open" )
      default: "circle"
      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.
    • opacity (number between or equal to 0 and 1)
      default: 1
      Sets the marker opacity.
    • size (number greater than or equal to 0)
      default: 6
      Sets the marker size (in px).
    • color (color)
      Sets the marker color. 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 `cmin` and `cmax` if set.
    • line
      • color (color)
        default: "#444"
        Sets the marker.line color. 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 `cmin` and `cmax` if set.
      • width (number greater than or equal to 0)
        default: 0
        Sets the width (in px) of the lines bounding the marker points.
      • outliercolor (color)
        Sets the border line color of the outlier sample points. Defaults to marker.color
      • outlierwidth (number greater than or equal to 0)
        default: 1
        Sets the border line width (in px) of the outlier sample points.
  • line
    • color (color)
      Sets the color of line bounding the box(es).
    • width (number greater than or equal to 0)
      default: 2
      Sets the width (in px) of line bounding the box(es).
  • fillcolor (color)
    Sets the fill color. Defaults to a half-transparent variant of the line color, marker color, or marker line color, whichever is available.
  • xaxis (subplotid)
    default: x
    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 to `layout.xaxis2`, and so on.
  • yaxis (subplotid)
    default: y
    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 to `layout.xaxis2`, and so on.
  • ysrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for y . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's y data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for x . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's x data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.

bar

import plotly.graph_objs as go
go.Bar
A Bar trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "x", "y", "z", "text", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "x", "y", "x+y", "x+y+z", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • x (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the x coordinates.
  • x0 (number or categorical coordinate string)
    default: 0
    Alternate to `x`. Builds a linear space of x coordinates. Use with `dx` where `x0` is the starting coordinate and `dx` the step.
  • dx (number)
    default: 1
    Sets the x coordinate step. See `x0` for more info.
  • y (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the y coordinates.
  • y0 (number or categorical coordinate string)
    default: 0
    Alternate to `y`. Builds a linear space of y coordinates. Use with `dy` where `y0` is the starting coordinate and `dy` the step.
  • dy (number)
    default: 1
    Sets the y coordinate step. See `y0` for more info.
  • text (string)
    default: ""
    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 `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
  • hovertext (string)
    default: ""
    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 `hoverinfo` must contain a "text" flag.
  • textposition (enumerated: "inside" | "outside" | "auto" | "none" )
    default: "none"
    Specifies the location of the `text`. "inside" positions `text` inside, next to the bar end (rotated and scaled if needed). "outside" positions `text` outside, next to the bar end (scaled if needed). "auto" positions `text` inside or outside so that `text` size is maximized.
  • textfont
    Sets the font used for `text`.
    • family (string)
      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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
    • color (color)
    • familysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for family . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's family data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • sizesrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for size . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's size data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • colorsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • insidetextfont
    Sets the font used for `text` lying inside the bar.
    • family (string)
      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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
    • color (color)
    • familysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for family . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's family data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • sizesrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for size . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's size data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • colorsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • outsidetextfont
    Sets the font used for `text` lying outside the bar.
    • family (string)
      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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
    • color (color)
    • familysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for family . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's family data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • sizesrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for size . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's size data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • colorsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • orientation (enumerated: "v" | "h" )
    Sets the orientation of the bars. With "v" ("h"), the value of the each bar spans along the vertical (horizontal).
  • base (number or categorical coordinate string)
    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.
  • offset (number)
    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.
  • width (number greater than or equal to 0)
    Sets the bar width (in position axis units).
  • marker
    • line
      • width (number greater than or equal to 0)
        default: 0
        Sets the width (in px) of the lines bounding the marker points.
      • color (color)
        Sets the marker.line color. 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 `cmin` and `cmax` if set.
      • colorscale (colorscale)
        Sets the colorscale and only has an effect if `marker.line.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.line.cmin` and `marker.line.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Greys, YlGnBu, Greens, YlOrRd, Bluered, RdBu, Reds, Blues, Picnic, Rainbow, Portland, Jet, Hot, Blackbody, Earth, Electric, Viridis
      • cauto (boolean)
        default: True
        Has an effect only if `marker.line.color` is set to a numerical array and `cmin`, `cmax` are set by the user. In this case, it controls whether the range of colors in `colorscale` is mapped to the range of values in the `color` array (`cauto: True`), or the `cmin`/`cmax` values (`cauto: False`). Defaults to `False` when `cmin`, `cmax` are set by the user.
      • cmax (number)
        Has an effect only if `marker.line.color` is set to a numerical array. Sets the upper bound of the color domain. Value should be associated to the `marker.line.color` array index, and if set, `marker.line.cmin` must be set as well.
      • cmin (number)
        Has an effect only if `marker.line.color` is set to a numerical array. Sets the lower bound of the color domain. Value should be associated to the `marker.line.color` array index, and if set, `marker.line.cmax` must be set as well.
      • autocolorscale (boolean)
        default: True
        Has an effect only if `marker.line.color` is set to a numerical array. Determines whether the colorscale is a default palette (`autocolorscale: True`) or the palette determined by `marker.line.colorscale`. In case `colorscale` is unspecified or `autocolorscale` is True, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
      • reversescale (boolean)
        Has an effect only if `marker.line.color` is set to a numerical array. Reverses the color mapping if True (`cmin` will correspond to the last color in the array and `cmax` will correspond to the first color).
      • widthsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for width . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's width data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
      • colorsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • color (color)
      Sets the marker color. 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 `cmin` and `cmax` if set.
    • colorscale (colorscale)
      Sets the colorscale and only has an effect if `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` and `marker.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Greys, YlGnBu, Greens, YlOrRd, Bluered, RdBu, Reds, Blues, Picnic, Rainbow, Portland, Jet, Hot, Blackbody, Earth, Electric, Viridis
    • cauto (boolean)
      default: True
      Has an effect only if `marker.color` is set to a numerical array and `cmin`, `cmax` are set by the user. In this case, it controls whether the range of colors in `colorscale` is mapped to the range of values in the `color` array (`cauto: True`), or the `cmin`/`cmax` values (`cauto: False`). Defaults to `False` when `cmin`, `cmax` are set by the user.
    • cmax (number)
      Has an effect only if `marker.color` is set to a numerical array. Sets the upper bound of the color domain. Value should be associated to the `marker.color` array index, and if set, `marker.cmin` must be set as well.
    • cmin (number)
      Has an effect only if `marker.color` is set to a numerical array. Sets the lower bound of the color domain. Value should be associated to the `marker.color` array index, and if set, `marker.cmax` must be set as well.
    • autocolorscale (boolean)
      default: True
      Has an effect only if `marker.color` is set to a numerical array. Determines whether the colorscale is a default palette (`autocolorscale: True`) or the palette determined by `marker.colorscale`. In case `colorscale` is unspecified or `autocolorscale` is True, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
    • reversescale (boolean)
      Has an effect only if `marker.color` is set to a numerical array. Reverses the color mapping if True (`cmin` will correspond to the last color in the array and `cmax` will correspond to the first color).
    • showscale (boolean)
      Has an effect only if `marker.color` is set to a numerical array. Determines whether or not a colorbar is displayed.
    • colorbar
      • thicknessmode (enumerated: "fraction" | "pixels" )
        default: "pixels"
        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 `thickness` to set the value.
      • thickness (number greater than or equal to 0)
        default: 30
        Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
      • lenmode (enumerated: "fraction" | "pixels" )
        default: "fraction"
        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 `len` to set the value.
      • len (number greater than or equal to 0)
        default: 1
        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.
      • x (number between or equal to -2 and 3)
        default: 1.02
        Sets the x position of the color bar (in plot fraction).
      • xanchor (enumerated: "left" | "center" | "right" )
        default: "left"
        Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the "left", "center" or "right" of the color bar.
      • xpad (number greater than or equal to 0)
        default: 10
        Sets the amount of padding (in px) along the x direction.
      • y (number between or equal to -2 and 3)
        default: 0.5
        Sets the y position of the color bar (in plot fraction).
      • yanchor (enumerated: "top" | "middle" | "bottom" )
        default: "middle"
        Sets this color bar's vertical position anchor This anchor binds the `y` position to the "top", "middle" or "bottom" of the color bar.
      • ypad (number greater than or equal to 0)
        default: 10
        Sets the amount of padding (in px) along the y direction.
      • outlinecolor (color)
        default: "#444"
        Sets the axis line color.
      • outlinewidth (number greater than or equal to 0)
        default: 1
        Sets the width (in px) of the axis line.
      • bordercolor (color)
        default: "#444"
        Sets the axis line color.
      • borderwidth (number greater than or equal to 0)
        default: 0
        Sets the width (in px) or the border enclosing this color bar.
      • bgcolor (color)
        default: "rgba(0,0,0,0)"
        Sets the color of padded area.
      • tickmode (enumerated: "auto" | "linear" | "array" )
        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 position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. ("array" is the default value if `tickvals` is provided).
      • nticks (integer greater than or equal to 0)
        default: 0
        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 if `tickmode` is set to "auto".
      • tick0 (number or categorical coordinate string)
        Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
      • dtick (number or categorical coordinate string)
        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 axis `type` is "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>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 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). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
      • tickvals (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
        Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `ticktext`.
      • ticktext (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
        Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to "array". Used with `tickvals`.
      • ticks (enumerated: "outside" | "inside" | "" )
        default: ""
        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.
      • ticklen (number greater than or equal to 0)
        default: 5
        Sets the tick length (in px).
      • tickwidth (number greater than or equal to 0)
        default: 1
        Sets the tick width (in px).
      • tickcolor (color)
        default: "#444"
        Sets the tick color.
      • showticklabels (boolean)
        default: True
        Determines whether or not the tick labels are drawn.
      • tickfont
        Sets the tick font.
        • family (string)
          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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
        • color (color)
      • tickangle (angle)
        default: auto
        Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
      • tickformat (string)
        default: ""
        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-format/blob/master/README.md#locale_format And for dates see: https://github.com/d3/d3-time-format/blob/master/README.md#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"
      • tickprefix (string)
        default: ""
        Sets a tick label prefix.
      • showtickprefix (enumerated: "all" | "first" | "last" | "none" )
        default: "all"
        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.
      • ticksuffix (string)
        default: ""
        Sets a tick label suffix.
      • showticksuffix (enumerated: "all" | "first" | "last" | "none" )
        default: "all"
        Same as `showtickprefix` but for tick suffixes.
      • separatethousands (boolean)
        If "True", even 4-digit integers are separated
      • exponentformat (enumerated: "none" | "e" | "E" | "power" | "SI" | "B" )
        default: "B"
        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.
      • showexponent (enumerated: "all" | "first" | "last" | "none" )
        default: "all"
        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.
      • title (string)
        default: "Click to enter colorscale title"
        Sets the title of the color bar.
      • titlefont
        Sets this color bar's title font.
        • family (string)
          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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
        • color (color)
      • titleside (enumerated: "right" | "top" | "bottom" )
        default: "top"
        Determines the location of the colorbar title with respect to the color bar.
      • tickvalssrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for tickvals . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's tickvals data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
      • ticktextsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for ticktext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's ticktext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • colorsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • r (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    For polar chart only.Sets the radial coordinates.
  • t (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    For polar chart only.Sets the angular coordinates.
  • error_y
    • visible (boolean)
      Determines whether or not this set of error bars is visible.
    • type (enumerated: "percent" | "constant" | "sqrt" | "data" )
      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 in `value`. If "sqrt", the bar lengths correspond to the sqaure of the underlying data. If "array", the bar lengths are set with data set `array`.
    • symmetric (boolean)
      Determines whether or not the error bars have the same length in both direction (top/bottom for vertical bars, left/right for horizontal bars.
    • array (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the data corresponding the length of each error bar. Values are plotted relative to the underlying data.
    • arrayminus (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      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.
    • value (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars.
    • valueminus (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars in the bottom (left) direction for vertical (horizontal) bars
    • traceref (integer greater than or equal to 0)
      default: 0
    • tracerefminus (integer greater than or equal to 0)
      default: 0
    • copy_ystyle (boolean)
    • copy_zstyle (boolean)
    • color (color)
      Sets the stoke color of the error bars.
    • thickness (number greater than or equal to 0)
      default: 2
      Sets the thickness (in px) of the error bars.
    • width (number greater than or equal to 0)
      Sets the width (in px) of the cross-bar at both ends of the error bars.
    • arraysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for array . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's array data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • arrayminussrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for arrayminus . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's arrayminus data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • error_x
    • visible (boolean)
      Determines whether or not this set of error bars is visible.
    • type (enumerated: "percent" | "constant" | "sqrt" | "data" )
      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 in `value`. If "sqrt", the bar lengths correspond to the sqaure of the underlying data. If "array", the bar lengths are set with data set `array`.
    • symmetric (boolean)
      Determines whether or not the error bars have the same length in both direction (top/bottom for vertical bars, left/right for horizontal bars.
    • array (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the data corresponding the length of each error bar. Values are plotted relative to the underlying data.
    • arrayminus (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      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.
    • value (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars.
    • valueminus (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars in the bottom (left) direction for vertical (horizontal) bars
    • traceref (integer greater than or equal to 0)
      default: 0
    • tracerefminus (integer greater than or equal to 0)
      default: 0
    • copy_ystyle (boolean)
    • copy_zstyle (boolean)
    • color (color)
      Sets the stoke color of the error bars.
    • thickness (number greater than or equal to 0)
      default: 2
      Sets the thickness (in px) of the error bars.
    • width (number greater than or equal to 0)
      Sets the width (in px) of the cross-bar at both ends of the error bars.
    • arraysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for array . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's array data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • arrayminussrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for arrayminus . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's arrayminus data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xaxis (subplotid)
    default: x
    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 to `layout.xaxis2`, and so on.
  • yaxis (subplotid)
    default: y
    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 to `layout.xaxis2`, and so on.
  • xcalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `x` date data.
  • ycalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `y` date data.
  • xsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for x . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's x data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • ysrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for y . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's y data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for text . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's text data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • hovertextsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for hovertext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's hovertext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textpositionsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for textposition . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's textposition data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • basesrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for base . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's base data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • offsetsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for offset . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's offset data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • widthsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for width . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's width data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • rsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for r . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's r data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • tsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for t . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's t data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.

heatmap

import plotly.graph_objs as go
go.Heatmap
A Heatmap trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "x", "y", "z", "text", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "x", "y", "x+y", "x+y+z", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • z (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the z data.
  • x (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the x coordinates.
  • x0 (number or categorical coordinate string)
    default: 0
    Alternate to `x`. Builds a linear space of x coordinates. Use with `dx` where `x0` is the starting coordinate and `dx` the step.
  • dx (number)
    default: 1
    Sets the x coordinate step. See `x0` for more info.
  • y (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the y coordinates.
  • y0 (number or categorical coordinate string)
    default: 0
    Alternate to `y`. Builds a linear space of y coordinates. Use with `dy` where `y0` is the starting coordinate and `dy` the step.
  • dy (number)
    default: 1
    Sets the y coordinate step. See `y0` for more info.
  • text (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the text elements associated with each z value.
  • transpose (boolean)
    Transposes the z data.
  • xtype (enumerated: "array" | "scaled" )
    If "array", the heatmap's x coordinates are given by "x" (the default behavior when `x` is provided). If "scaled", the heatmap's x coordinates are given by "x0" and "dx" (the default behavior when `x` is not provided).
  • ytype (enumerated: "array" | "scaled" )
    If "array", the heatmap's y coordinates are given by "y" (the default behavior when `y` is provided) If "scaled", the heatmap's y coordinates are given by "y0" and "dy" (the default behavior when `y` is not provided)
  • zsmooth (enumerated: "fast" | "best" | False )
    Picks a smoothing algorithm use to smooth `z` data.
  • connectgaps (boolean)
    Determines whether or not gaps (i.e. {nan} or missing values) in the `z` data are filled in.
  • xgap (number greater than or equal to 0)
    default: 0
    Sets the horizontal gap (in pixels) between bricks.
  • ygap (number greater than or equal to 0)
    default: 0
    Sets the vertical gap (in pixels) between bricks.
  • zauto (boolean)
    default: True
    Determines the whether or not the color domain is computed with respect to the input data.
  • zmin (number)
    Sets the lower bound of color domain.
  • zmax (number)
    Sets the upper bound of color domain.
  • colorscale (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 z space, use zmin and zmax
  • autocolorscale (boolean)
    Determines whether or not the colorscale is picked using the sign of the input z values.
  • reversescale (boolean)
    Reverses the colorscale.
  • showscale (boolean)
    default: True
    Determines whether or not a colorbar is displayed for this trace.
  • colorbar
    • thicknessmode (enumerated: "fraction" | "pixels" )
      default: "pixels"
      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 `thickness` to set the value.
    • thickness (number greater than or equal to 0)
      default: 30
      Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
    • lenmode (enumerated: "fraction" | "pixels" )
      default: "fraction"
      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 `len` to set the value.
    • len (number greater than or equal to 0)
      default: 1
      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.
    • x (number between or equal to -2 and 3)
      default: 1.02
      Sets the x position of the color bar (in plot fraction).
    • xanchor (enumerated: "left" | "center" | "right" )
      default: "left"
      Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the "left", "center" or "right" of the color bar.
    • xpad (number greater than or equal to 0)
      default: 10
      Sets the amount of padding (in px) along the x direction.
    • y (number between or equal to -2 and 3)
      default: 0.5
      Sets the y position of the color bar (in plot fraction).
    • yanchor (enumerated: "top" | "middle" | "bottom" )
      default: "middle"
      Sets this color bar's vertical position anchor This anchor binds the `y` position to the "top", "middle" or "bottom" of the color bar.
    • ypad (number greater than or equal to 0)
      default: 10
      Sets the amount of padding (in px) along the y direction.
    • outlinecolor (color)
      default: "#444"
      Sets the axis line color.
    • outlinewidth (number greater than or equal to 0)
      default: 1
      Sets the width (in px) of the axis line.
    • bordercolor (color)
      default: "#444"
      Sets the axis line color.
    • borderwidth (number greater than or equal to 0)
      default: 0
      Sets the width (in px) or the border enclosing this color bar.
    • bgcolor (color)
      default: "rgba(0,0,0,0)"
      Sets the color of padded area.
    • tickmode (enumerated: "auto" | "linear" | "array" )
      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 position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. ("array" is the default value if `tickvals` is provided).
    • nticks (integer greater than or equal to 0)
      default: 0
      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 if `tickmode` is set to "auto".
    • tick0 (number or categorical coordinate string)
      Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
    • dtick (number or categorical coordinate string)
      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 axis `type` is "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>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 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). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
    • tickvals (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `ticktext`.
    • ticktext (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to "array". Used with `tickvals`.
    • ticks (enumerated: "outside" | "inside" | "" )
      default: ""
      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.
    • ticklen (number greater than or equal to 0)
      default: 5
      Sets the tick length (in px).
    • tickwidth (number greater than or equal to 0)
      default: 1
      Sets the tick width (in px).
    • tickcolor (color)
      default: "#444"
      Sets the tick color.
    • showticklabels (boolean)
      default: True
      Determines whether or not the tick labels are drawn.
    • tickfont
      Sets the tick font.
      • family (string)
        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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
      • color (color)
    • tickangle (angle)
      default: auto
      Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
    • tickformat (string)
      default: ""
      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-format/blob/master/README.md#locale_format And for dates see: https://github.com/d3/d3-time-format/blob/master/README.md#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"
    • tickprefix (string)
      default: ""
      Sets a tick label prefix.
    • showtickprefix (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      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.
    • ticksuffix (string)
      default: ""
      Sets a tick label suffix.
    • showticksuffix (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      Same as `showtickprefix` but for tick suffixes.
    • separatethousands (boolean)
      If "True", even 4-digit integers are separated
    • exponentformat (enumerated: "none" | "e" | "E" | "power" | "SI" | "B" )
      default: "B"
      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.
    • showexponent (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      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.
    • title (string)
      default: "Click to enter colorscale title"
      Sets the title of the color bar.
    • titlefont
      Sets this color bar's title font.
      • family (string)
        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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
      • color (color)
    • titleside (enumerated: "right" | "top" | "bottom" )
      default: "top"
      Determines the location of the colorbar title with respect to the color bar.
    • tickvalssrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for tickvals . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's tickvals data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • ticktextsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for ticktext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's ticktext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xaxis (subplotid)
    default: x
    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 to `layout.xaxis2`, and so on.
  • yaxis (subplotid)
    default: y
    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 to `layout.xaxis2`, and so on.
  • xcalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `x` date data.
  • ycalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `y` date data.
  • zsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for z . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's z data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for x . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's x data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • ysrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for y . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's y data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for text . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's text data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.

histogram

import plotly.graph_objs as go
go.Histogram
A Histogram trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "x", "y", "z", "text", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "x", "y", "x+y", "x+y+z", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • x (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the sample data to be binned on the x axis.
  • y (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the sample data to be binned on the y axis.
  • text (string)
    default: ""
    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 `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
  • orientation (enumerated: "v" | "h" )
    Sets the orientation of the bars. With "v" ("h"), the value of the each bar spans along the vertical (horizontal).
  • histfunc (enumerated: "count" | "sum" | "avg" | "min" | "max" )
    default: "count"
    Specifies the binning function used for this histogram trace. If "count", the histogram values are computed by counting the number of values lying inside each bin. If "sum", "avg", "min", "max", the histogram values are computed using the sum, the average, the minimum or the maximum of the values lying inside each bin respectively.
  • histnorm (enumerated: "" | "percent" | "probability" | "density" | "probability density" )
    default: ""
    Specifies the type of normalization used for this histogram trace. If "", the span of each bar corresponds to the number of occurrences (i.e. the number of data points lying inside the bins). If "percent" / "probability", the span of each bar corresponds to the percentage / fraction of occurrences with respect to the total number of sample points (here, the sum of all bin HEIGHTS equals 100% / 1). If "density", the span of each bar corresponds to the number of occurrences in a bin divided by the size of the bin interval (here, the sum of all bin AREAS equals the total number of sample points). If "probability density", the area of each bar corresponds to the probability that an event will fall into the corresponding bin (here, the sum of all bin AREAS equals 1).
  • cumulative
    • enabled (boolean)
      If True, display the cumulative distribution by summing the binned values. Use the `direction` and `centralbin` attributes to tune the accumulation method. Note: in this mode, the "density" `histnorm` settings behave the same as their equivalents without "density": "" and "density" both rise to the number of data points, and "probability" and "probability density" both rise to the number of sample points.
    • direction (enumerated: "increasing" | "decreasing" )
      default: "increasing"
      Only applies if cumulative is enabled. If "increasing" (default) we sum all prior bins, so the result increases from left to right. If "decreasing" we sum later bins so the result decreases from left to right.
    • currentbin (enumerated: "include" | "exclude" | "half" )
      default: "include"
      Only applies if cumulative is enabled. Sets whether the current bin is included, excluded, or has half of its value included in the current cumulative value. "include" is the default for compatibility with various other tools, however it introduces a half-bin bias to the results. "exclude" makes the opposite half-bin bias, and "half" removes it.
  • autobinx (boolean)
    Determines whether or not the x axis bin attributes are picked by an algorithm. Note that this should be set to False if you want to manually set the number of bins using the attributes in xbins.
  • nbinsx (integer greater than or equal to 0)
    default: 0
    Specifies the maximum number of desired bins. This value will be used in an algorithm that will decide the optimal bin size such that the histogram best visualizes the distribution of the data.
  • xbins
    • start (number or categorical coordinate string)
      Sets the starting value for the x axis bins.
    • end (number or categorical coordinate string)
      Sets the end value for the x axis bins.
    • size (number or categorical coordinate string)
      Sets the step in-between value each x axis bin.
  • autobiny (boolean)
    Determines whether or not the y axis bin attributes are picked by an algorithm. Note that this should be set to False if you want to manually set the number of bins using the attributes in ybins.
  • nbinsy (integer greater than or equal to 0)
    default: 0
    Specifies the maximum number of desired bins. This value will be used in an algorithm that will decide the optimal bin size such that the histogram best visualizes the distribution of the data.
  • ybins
    • start (number or categorical coordinate string)
      Sets the starting value for the y axis bins.
    • end (number or categorical coordinate string)
      Sets the end value for the y axis bins.
    • size (number or categorical coordinate string)
      Sets the step in-between value each y axis bin.
  • marker
    • line
      • width (number greater than or equal to 0)
        default: 0
        Sets the width (in px) of the lines bounding the marker points.
      • color (color)
        Sets the marker.line color. 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 `cmin` and `cmax` if set.
      • colorscale (colorscale)
        Sets the colorscale and only has an effect if `marker.line.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.line.cmin` and `marker.line.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Greys, YlGnBu, Greens, YlOrRd, Bluered, RdBu, Reds, Blues, Picnic, Rainbow, Portland, Jet, Hot, Blackbody, Earth, Electric, Viridis
      • cauto (boolean)
        default: True
        Has an effect only if `marker.line.color` is set to a numerical array and `cmin`, `cmax` are set by the user. In this case, it controls whether the range of colors in `colorscale` is mapped to the range of values in the `color` array (`cauto: True`), or the `cmin`/`cmax` values (`cauto: False`). Defaults to `False` when `cmin`, `cmax` are set by the user.
      • cmax (number)
        Has an effect only if `marker.line.color` is set to a numerical array. Sets the upper bound of the color domain. Value should be associated to the `marker.line.color` array index, and if set, `marker.line.cmin` must be set as well.
      • cmin (number)
        Has an effect only if `marker.line.color` is set to a numerical array. Sets the lower bound of the color domain. Value should be associated to the `marker.line.color` array index, and if set, `marker.line.cmax` must be set as well.
      • autocolorscale (boolean)
        default: True
        Has an effect only if `marker.line.color` is set to a numerical array. Determines whether the colorscale is a default palette (`autocolorscale: True`) or the palette determined by `marker.line.colorscale`. In case `colorscale` is unspecified or `autocolorscale` is True, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
      • reversescale (boolean)
        Has an effect only if `marker.line.color` is set to a numerical array. Reverses the color mapping if True (`cmin` will correspond to the last color in the array and `cmax` will correspond to the first color).
      • widthsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for width . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's width data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
      • colorsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • color (color)
      Sets the marker color. 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 `cmin` and `cmax` if set.
    • colorscale (colorscale)
      Sets the colorscale and only has an effect if `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` and `marker.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Greys, YlGnBu, Greens, YlOrRd, Bluered, RdBu, Reds, Blues, Picnic, Rainbow, Portland, Jet, Hot, Blackbody, Earth, Electric, Viridis
    • cauto (boolean)
      default: True
      Has an effect only if `marker.color` is set to a numerical array and `cmin`, `cmax` are set by the user. In this case, it controls whether the range of colors in `colorscale` is mapped to the range of values in the `color` array (`cauto: True`), or the `cmin`/`cmax` values (`cauto: False`). Defaults to `False` when `cmin`, `cmax` are set by the user.
    • cmax (number)
      Has an effect only if `marker.color` is set to a numerical array. Sets the upper bound of the color domain. Value should be associated to the `marker.color` array index, and if set, `marker.cmin` must be set as well.
    • cmin (number)
      Has an effect only if `marker.color` is set to a numerical array. Sets the lower bound of the color domain. Value should be associated to the `marker.color` array index, and if set, `marker.cmax` must be set as well.
    • autocolorscale (boolean)
      default: True
      Has an effect only if `marker.color` is set to a numerical array. Determines whether the colorscale is a default palette (`autocolorscale: True`) or the palette determined by `marker.colorscale`. In case `colorscale` is unspecified or `autocolorscale` is True, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
    • reversescale (boolean)
      Has an effect only if `marker.color` is set to a numerical array. Reverses the color mapping if True (`cmin` will correspond to the last color in the array and `cmax` will correspond to the first color).
    • showscale (boolean)
      Has an effect only if `marker.color` is set to a numerical array. Determines whether or not a colorbar is displayed.
    • colorbar
      • thicknessmode (enumerated: "fraction" | "pixels" )
        default: "pixels"
        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 `thickness` to set the value.
      • thickness (number greater than or equal to 0)
        default: 30
        Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
      • lenmode (enumerated: "fraction" | "pixels" )
        default: "fraction"
        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 `len` to set the value.
      • len (number greater than or equal to 0)
        default: 1
        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.
      • x (number between or equal to -2 and 3)
        default: 1.02
        Sets the x position of the color bar (in plot fraction).
      • xanchor (enumerated: "left" | "center" | "right" )
        default: "left"
        Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the "left", "center" or "right" of the color bar.
      • xpad (number greater than or equal to 0)
        default: 10
        Sets the amount of padding (in px) along the x direction.
      • y (number between or equal to -2 and 3)
        default: 0.5
        Sets the y position of the color bar (in plot fraction).
      • yanchor (enumerated: "top" | "middle" | "bottom" )
        default: "middle"
        Sets this color bar's vertical position anchor This anchor binds the `y` position to the "top", "middle" or "bottom" of the color bar.
      • ypad (number greater than or equal to 0)
        default: 10
        Sets the amount of padding (in px) along the y direction.
      • outlinecolor (color)
        default: "#444"
        Sets the axis line color.
      • outlinewidth (number greater than or equal to 0)
        default: 1
        Sets the width (in px) of the axis line.
      • bordercolor (color)
        default: "#444"
        Sets the axis line color.
      • borderwidth (number greater than or equal to 0)
        default: 0
        Sets the width (in px) or the border enclosing this color bar.
      • bgcolor (color)
        default: "rgba(0,0,0,0)"
        Sets the color of padded area.
      • tickmode (enumerated: "auto" | "linear" | "array" )
        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 position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. ("array" is the default value if `tickvals` is provided).
      • nticks (integer greater than or equal to 0)
        default: 0
        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 if `tickmode` is set to "auto".
      • tick0 (number or categorical coordinate string)
        Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
      • dtick (number or categorical coordinate string)
        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 axis `type` is "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>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 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). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
      • tickvals (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
        Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `ticktext`.
      • ticktext (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
        Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to "array". Used with `tickvals`.
      • ticks (enumerated: "outside" | "inside" | "" )
        default: ""
        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.
      • ticklen (number greater than or equal to 0)
        default: 5
        Sets the tick length (in px).
      • tickwidth (number greater than or equal to 0)
        default: 1
        Sets the tick width (in px).
      • tickcolor (color)
        default: "#444"
        Sets the tick color.
      • showticklabels (boolean)
        default: True
        Determines whether or not the tick labels are drawn.
      • tickfont
        Sets the tick font.
        • family (string)
          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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
        • color (color)
      • tickangle (angle)
        default: auto
        Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
      • tickformat (string)
        default: ""
        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-format/blob/master/README.md#locale_format And for dates see: https://github.com/d3/d3-time-format/blob/master/README.md#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"
      • tickprefix (string)
        default: ""
        Sets a tick label prefix.
      • showtickprefix (enumerated: "all" | "first" | "last" | "none" )
        default: "all"
        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.
      • ticksuffix (string)
        default: ""
        Sets a tick label suffix.
      • showticksuffix (enumerated: "all" | "first" | "last" | "none" )
        default: "all"
        Same as `showtickprefix` but for tick suffixes.
      • separatethousands (boolean)
        If "True", even 4-digit integers are separated
      • exponentformat (enumerated: "none" | "e" | "E" | "power" | "SI" | "B" )
        default: "B"
        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.
      • showexponent (enumerated: "all" | "first" | "last" | "none" )
        default: "all"
        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.
      • title (string)
        default: "Click to enter colorscale title"
        Sets the title of the color bar.
      • titlefont
        Sets this color bar's title font.
        • family (string)
          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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
        • color (color)
      • titleside (enumerated: "right" | "top" | "bottom" )
        default: "top"
        Determines the location of the colorbar title with respect to the color bar.
      • tickvalssrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for tickvals . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's tickvals data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
      • ticktextsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for ticktext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's ticktext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • colorsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • error_y
    • visible (boolean)
      Determines whether or not this set of error bars is visible.
    • type (enumerated: "percent" | "constant" | "sqrt" | "data" )
      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 in `value`. If "sqrt", the bar lengths correspond to the sqaure of the underlying data. If "array", the bar lengths are set with data set `array`.
    • symmetric (boolean)
      Determines whether or not the error bars have the same length in both direction (top/bottom for vertical bars, left/right for horizontal bars.
    • array (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the data corresponding the length of each error bar. Values are plotted relative to the underlying data.
    • arrayminus (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      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.
    • value (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars.
    • valueminus (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars in the bottom (left) direction for vertical (horizontal) bars
    • traceref (integer greater than or equal to 0)
      default: 0
    • tracerefminus (integer greater than or equal to 0)
      default: 0
    • copy_ystyle (boolean)
    • copy_zstyle (boolean)
    • color (color)
      Sets the stoke color of the error bars.
    • thickness (number greater than or equal to 0)
      default: 2
      Sets the thickness (in px) of the error bars.
    • width (number greater than or equal to 0)
      Sets the width (in px) of the cross-bar at both ends of the error bars.
    • arraysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for array . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's array data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • arrayminussrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for arrayminus . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's arrayminus data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • error_x
    • visible (boolean)
      Determines whether or not this set of error bars is visible.
    • type (enumerated: "percent" | "constant" | "sqrt" | "data" )
      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 in `value`. If "sqrt", the bar lengths correspond to the sqaure of the underlying data. If "array", the bar lengths are set with data set `array`.
    • symmetric (boolean)
      Determines whether or not the error bars have the same length in both direction (top/bottom for vertical bars, left/right for horizontal bars.
    • array (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the data corresponding the length of each error bar. Values are plotted relative to the underlying data.
    • arrayminus (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      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.
    • value (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars.
    • valueminus (number greater than or equal to 0)
      default: 10
      Sets the value of either the percentage (if `type` is set to "percent") or the constant (if `type` is set to "constant") corresponding to the lengths of the error bars in the bottom (left) direction for vertical (horizontal) bars
    • traceref (integer greater than or equal to 0)
      default: 0
    • tracerefminus (integer greater than or equal to 0)
      default: 0
    • copy_ystyle (boolean)
    • copy_zstyle (boolean)
    • color (color)
      Sets the stoke color of the error bars.
    • thickness (number greater than or equal to 0)
      default: 2
      Sets the thickness (in px) of the error bars.
    • width (number greater than or equal to 0)
      Sets the width (in px) of the cross-bar at both ends of the error bars.
    • arraysrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for array . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's array data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • arrayminussrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for arrayminus . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's arrayminus data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xaxis (subplotid)
    default: x
    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 to `layout.xaxis2`, and so on.
  • yaxis (subplotid)
    default: y
    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 to `layout.xaxis2`, and so on.
  • xcalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `x` date data.
  • ycalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `y` date data.
  • xsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for x . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's x data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • ysrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for y . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's y data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for text . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's text data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.

histogram2d

import plotly.graph_objs as go
go.Histogram2D
A Histogram2D trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "x", "y", "z", "text", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "x", "y", "x+y", "x+y+z", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • x (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the sample data to be binned on the x axis.
  • y (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the sample data to be binned on the y axis.
  • z (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the aggregation data.
  • marker
    • color (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the aggregation data.
    • colorsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • histnorm (enumerated: "" | "percent" | "probability" | "density" | "probability density" )
    default: ""
    Specifies the type of normalization used for this histogram trace. If "", the span of each bar corresponds to the number of occurrences (i.e. the number of data points lying inside the bins). If "percent" / "probability", the span of each bar corresponds to the percentage / fraction of occurrences with respect to the total number of sample points (here, the sum of all bin HEIGHTS equals 100% / 1). If "density", the span of each bar corresponds to the number of occurrences in a bin divided by the size of the bin interval (here, the sum of all bin AREAS equals the total number of sample points). If "probability density", the area of each bar corresponds to the probability that an event will fall into the corresponding bin (here, the sum of all bin AREAS equals 1).
  • histfunc (enumerated: "count" | "sum" | "avg" | "min" | "max" )
    default: "count"
    Specifies the binning function used for this histogram trace. If "count", the histogram values are computed by counting the number of values lying inside each bin. If "sum", "avg", "min", "max", the histogram values are computed using the sum, the average, the minimum or the maximum of the values lying inside each bin respectively.
  • autobinx (boolean)
    Determines whether or not the x axis bin attributes are picked by an algorithm. Note that this should be set to False if you want to manually set the number of bins using the attributes in xbins.
  • nbinsx (integer greater than or equal to 0)
    default: 0
    Specifies the maximum number of desired bins. This value will be used in an algorithm that will decide the optimal bin size such that the histogram best visualizes the distribution of the data.
  • xbins
    • start (number or categorical coordinate string)
      Sets the starting value for the x axis bins.
    • end (number or categorical coordinate string)
      Sets the end value for the x axis bins.
    • size (number or categorical coordinate string)
      Sets the step in-between value each x axis bin.
  • autobiny (boolean)
    Determines whether or not the y axis bin attributes are picked by an algorithm. Note that this should be set to False if you want to manually set the number of bins using the attributes in ybins.
  • nbinsy (integer greater than or equal to 0)
    default: 0
    Specifies the maximum number of desired bins. This value will be used in an algorithm that will decide the optimal bin size such that the histogram best visualizes the distribution of the data.
  • ybins
    • start (number or categorical coordinate string)
      Sets the starting value for the y axis bins.
    • end (number or categorical coordinate string)
      Sets the end value for the y axis bins.
    • size (number or categorical coordinate string)
      Sets the step in-between value each y axis bin.
  • xgap (number greater than or equal to 0)
    default: 0
    Sets the horizontal gap (in pixels) between bricks.
  • ygap (number greater than or equal to 0)
    default: 0
    Sets the vertical gap (in pixels) between bricks.
  • zsmooth (enumerated: "fast" | "best" | False )
    Picks a smoothing algorithm use to smooth `z` data.
  • zauto (boolean)
    default: True
    Determines the whether or not the color domain is computed with respect to the input data.
  • zmin (number)
    Sets the lower bound of color domain.
  • zmax (number)
    Sets the upper bound of color domain.
  • colorscale (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 z space, use zmin and zmax
  • autocolorscale (boolean)
    Determines whether or not the colorscale is picked using the sign of the input z values.
  • reversescale (boolean)
    Reverses the colorscale.
  • showscale (boolean)
    default: True
    Determines whether or not a colorbar is displayed for this trace.
  • colorbar
    • thicknessmode (enumerated: "fraction" | "pixels" )
      default: "pixels"
      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 `thickness` to set the value.
    • thickness (number greater than or equal to 0)
      default: 30
      Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
    • lenmode (enumerated: "fraction" | "pixels" )
      default: "fraction"
      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 `len` to set the value.
    • len (number greater than or equal to 0)
      default: 1
      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.
    • x (number between or equal to -2 and 3)
      default: 1.02
      Sets the x position of the color bar (in plot fraction).
    • xanchor (enumerated: "left" | "center" | "right" )
      default: "left"
      Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the "left", "center" or "right" of the color bar.
    • xpad (number greater than or equal to 0)
      default: 10
      Sets the amount of padding (in px) along the x direction.
    • y (number between or equal to -2 and 3)
      default: 0.5
      Sets the y position of the color bar (in plot fraction).
    • yanchor (enumerated: "top" | "middle" | "bottom" )
      default: "middle"
      Sets this color bar's vertical position anchor This anchor binds the `y` position to the "top", "middle" or "bottom" of the color bar.
    • ypad (number greater than or equal to 0)
      default: 10
      Sets the amount of padding (in px) along the y direction.
    • outlinecolor (color)
      default: "#444"
      Sets the axis line color.
    • outlinewidth (number greater than or equal to 0)
      default: 1
      Sets the width (in px) of the axis line.
    • bordercolor (color)
      default: "#444"
      Sets the axis line color.
    • borderwidth (number greater than or equal to 0)
      default: 0
      Sets the width (in px) or the border enclosing this color bar.
    • bgcolor (color)
      default: "rgba(0,0,0,0)"
      Sets the color of padded area.
    • tickmode (enumerated: "auto" | "linear" | "array" )
      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 position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. ("array" is the default value if `tickvals` is provided).
    • nticks (integer greater than or equal to 0)
      default: 0
      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 if `tickmode` is set to "auto".
    • tick0 (number or categorical coordinate string)
      Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
    • dtick (number or categorical coordinate string)
      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 axis `type` is "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>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 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). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
    • tickvals (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `ticktext`.
    • ticktext (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to "array". Used with `tickvals`.
    • ticks (enumerated: "outside" | "inside" | "" )
      default: ""
      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.
    • ticklen (number greater than or equal to 0)
      default: 5
      Sets the tick length (in px).
    • tickwidth (number greater than or equal to 0)
      default: 1
      Sets the tick width (in px).
    • tickcolor (color)
      default: "#444"
      Sets the tick color.
    • showticklabels (boolean)
      default: True
      Determines whether or not the tick labels are drawn.
    • tickfont
      Sets the tick font.
      • family (string)
        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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
      • color (color)
    • tickangle (angle)
      default: auto
      Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
    • tickformat (string)
      default: ""
      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-format/blob/master/README.md#locale_format And for dates see: https://github.com/d3/d3-time-format/blob/master/README.md#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"
    • tickprefix (string)
      default: ""
      Sets a tick label prefix.
    • showtickprefix (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      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.
    • ticksuffix (string)
      default: ""
      Sets a tick label suffix.
    • showticksuffix (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      Same as `showtickprefix` but for tick suffixes.
    • separatethousands (boolean)
      If "True", even 4-digit integers are separated
    • exponentformat (enumerated: "none" | "e" | "E" | "power" | "SI" | "B" )
      default: "B"
      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.
    • showexponent (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      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.
    • title (string)
      default: "Click to enter colorscale title"
      Sets the title of the color bar.
    • titlefont
      Sets this color bar's title font.
      • family (string)
        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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
      • color (color)
    • titleside (enumerated: "right" | "top" | "bottom" )
      default: "top"
      Determines the location of the colorbar title with respect to the color bar.
    • tickvalssrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for tickvals . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's tickvals data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • ticktextsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for ticktext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's ticktext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xaxis (subplotid)
    default: x
    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 to `layout.xaxis2`, and so on.
  • yaxis (subplotid)
    default: y
    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 to `layout.xaxis2`, and so on.
  • xcalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `x` date data.
  • ycalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `y` date data.
  • xsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for x . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's x data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • ysrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for y . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's y data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • zsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for z . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's z data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.

histogram2dcontour

import plotly.graph_objs as go
go.Histogram2Dcontour
A Histogram2Dcontour trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "x", "y", "z", "text", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "x", "y", "x+y", "x+y+z", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • x (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the sample data to be binned on the x axis.
  • y (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the sample data to be binned on the y axis.
  • z (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the aggregation data.
  • marker
    • color (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the aggregation data.
    • colorsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • histnorm (enumerated: "" | "percent" | "probability" | "density" | "probability density" )
    default: ""
    Specifies the type of normalization used for this histogram trace. If "", the span of each bar corresponds to the number of occurrences (i.e. the number of data points lying inside the bins). If "percent" / "probability", the span of each bar corresponds to the percentage / fraction of occurrences with respect to the total number of sample points (here, the sum of all bin HEIGHTS equals 100% / 1). If "density", the span of each bar corresponds to the number of occurrences in a bin divided by the size of the bin interval (here, the sum of all bin AREAS equals the total number of sample points). If "probability density", the area of each bar corresponds to the probability that an event will fall into the corresponding bin (here, the sum of all bin AREAS equals 1).
  • histfunc (enumerated: "count" | "sum" | "avg" | "min" | "max" )
    default: "count"
    Specifies the binning function used for this histogram trace. If "count", the histogram values are computed by counting the number of values lying inside each bin. If "sum", "avg", "min", "max", the histogram values are computed using the sum, the average, the minimum or the maximum of the values lying inside each bin respectively.
  • autobinx (boolean)
    Determines whether or not the x axis bin attributes are picked by an algorithm. Note that this should be set to False if you want to manually set the number of bins using the attributes in xbins.
  • nbinsx (integer greater than or equal to 0)
    default: 0
    Specifies the maximum number of desired bins. This value will be used in an algorithm that will decide the optimal bin size such that the histogram best visualizes the distribution of the data.
  • xbins
    • start (number or categorical coordinate string)
      Sets the starting value for the x axis bins.
    • end (number or categorical coordinate string)
      Sets the end value for the x axis bins.
    • size (number or categorical coordinate string)
      Sets the step in-between value each x axis bin.
  • autobiny (boolean)
    Determines whether or not the y axis bin attributes are picked by an algorithm. Note that this should be set to False if you want to manually set the number of bins using the attributes in ybins.
  • nbinsy (integer greater than or equal to 0)
    default: 0
    Specifies the maximum number of desired bins. This value will be used in an algorithm that will decide the optimal bin size such that the histogram best visualizes the distribution of the data.
  • ybins
    • start (number or categorical coordinate string)
      Sets the starting value for the y axis bins.
    • end (number or categorical coordinate string)
      Sets the end value for the y axis bins.
    • size (number or categorical coordinate string)
      Sets the step in-between value each y axis bin.
  • autocontour (boolean)
    default: True
    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 in `contours`.
  • ncontours (integer greater than or equal to 1)
    default: 15
    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 if `autocontour` is "True" or if `contours.size` is missing.
  • contours
    • start (number)
      Sets the starting contour level value. Must be less than `contours.end`
    • end (number)
      Sets the end contour level value. Must be more than `contours.start`
    • size (number greater than or equal to 0)
      Sets the step between each contour level. Must be positive.
    • coloring (enumerated: "fill" | "heatmap" | "lines" | "none" )
      default: "fill"
      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.
    • showlines (boolean)
      default: True
      Determines whether or not the contour lines are drawn. Has only an effect if `contours.coloring` is set to "fill".
  • line
    • color (color)
      Sets the color of the contour level. Has no if `contours.coloring` is set to "lines".
    • width (number greater than or equal to 0)
      default: 2
      Sets the line width (in px).
    • dash (string)
      default: "solid"
      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 (number between or equal to 0 and 1.3)
      default: 1
      Sets the amount of smoothing for the contour lines, where "0" corresponds to no smoothing.
  • zauto (boolean)
    default: True
    Determines the whether or not the color domain is computed with respect to the input data.
  • zmin (number)
    Sets the lower bound of color domain.
  • zmax (number)
    Sets the upper bound of color domain.
  • colorscale (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 z space, use zmin and zmax
  • autocolorscale (boolean)
    default: True
    Determines whether or not the colorscale is picked using the sign of the input z values.
  • reversescale (boolean)
    Reverses the colorscale.
  • showscale (boolean)
    default: True
    Determines whether or not a colorbar is displayed for this trace.
  • colorbar
    • thicknessmode (enumerated: "fraction" | "pixels" )
      default: "pixels"
      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 `thickness` to set the value.
    • thickness (number greater than or equal to 0)
      default: 30
      Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
    • lenmode (enumerated: "fraction" | "pixels" )
      default: "fraction"
      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 `len` to set the value.
    • len (number greater than or equal to 0)
      default: 1
      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.
    • x (number between or equal to -2 and 3)
      default: 1.02
      Sets the x position of the color bar (in plot fraction).
    • xanchor (enumerated: "left" | "center" | "right" )
      default: "left"
      Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the "left", "center" or "right" of the color bar.
    • xpad (number greater than or equal to 0)
      default: 10
      Sets the amount of padding (in px) along the x direction.
    • y (number between or equal to -2 and 3)
      default: 0.5
      Sets the y position of the color bar (in plot fraction).
    • yanchor (enumerated: "top" | "middle" | "bottom" )
      default: "middle"
      Sets this color bar's vertical position anchor This anchor binds the `y` position to the "top", "middle" or "bottom" of the color bar.
    • ypad (number greater than or equal to 0)
      default: 10
      Sets the amount of padding (in px) along the y direction.
    • outlinecolor (color)
      default: "#444"
      Sets the axis line color.
    • outlinewidth (number greater than or equal to 0)
      default: 1
      Sets the width (in px) of the axis line.
    • bordercolor (color)
      default: "#444"
      Sets the axis line color.
    • borderwidth (number greater than or equal to 0)
      default: 0
      Sets the width (in px) or the border enclosing this color bar.
    • bgcolor (color)
      default: "rgba(0,0,0,0)"
      Sets the color of padded area.
    • tickmode (enumerated: "auto" | "linear" | "array" )
      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 position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. ("array" is the default value if `tickvals` is provided).
    • nticks (integer greater than or equal to 0)
      default: 0
      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 if `tickmode` is set to "auto".
    • tick0 (number or categorical coordinate string)
      Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
    • dtick (number or categorical coordinate string)
      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 axis `type` is "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>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 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). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
    • tickvals (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `ticktext`.
    • ticktext (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to "array". Used with `tickvals`.
    • ticks (enumerated: "outside" | "inside" | "" )
      default: ""
      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.
    • ticklen (number greater than or equal to 0)
      default: 5
      Sets the tick length (in px).
    • tickwidth (number greater than or equal to 0)
      default: 1
      Sets the tick width (in px).
    • tickcolor (color)
      default: "#444"
      Sets the tick color.
    • showticklabels (boolean)
      default: True
      Determines whether or not the tick labels are drawn.
    • tickfont
      Sets the tick font.
      • family (string)
        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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
      • color (color)
    • tickangle (angle)
      default: auto
      Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
    • tickformat (string)
      default: ""
      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-format/blob/master/README.md#locale_format And for dates see: https://github.com/d3/d3-time-format/blob/master/README.md#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"
    • tickprefix (string)
      default: ""
      Sets a tick label prefix.
    • showtickprefix (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      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.
    • ticksuffix (string)
      default: ""
      Sets a tick label suffix.
    • showticksuffix (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      Same as `showtickprefix` but for tick suffixes.
    • separatethousands (boolean)
      If "True", even 4-digit integers are separated
    • exponentformat (enumerated: "none" | "e" | "E" | "power" | "SI" | "B" )
      default: "B"
      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.
    • showexponent (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      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.
    • title (string)
      default: "Click to enter colorscale title"
      Sets the title of the color bar.
    • titlefont
      Sets this color bar's title font.
      • family (string)
        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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
      • color (color)
    • titleside (enumerated: "right" | "top" | "bottom" )
      default: "top"
      Determines the location of the colorbar title with respect to the color bar.
    • tickvalssrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for tickvals . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's tickvals data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • ticktextsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for ticktext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's ticktext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xaxis (subplotid)
    default: x
    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 to `layout.xaxis2`, and so on.
  • yaxis (subplotid)
    default: y
    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 to `layout.xaxis2`, and so on.
  • xcalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `x` date data.
  • ycalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `y` date data.
  • xsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for x . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's x data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • ysrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for y . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's y data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • zsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for z . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's z data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.

pie

import plotly.graph_objs as go
go.Pie
A Pie trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "label", "text", "value", "percent", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "label", "text", "label+text", "label+text+value", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • labels (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the sector labels.
  • label0 (number)
    default: 0
    Alternate to `labels`. Builds a numeric set of labels. Use with `dlabel` where `label0` is the starting label and `dlabel` the step.
  • dlabel (number)
    default: 1
    Sets the label step. See `label0` for more info.
  • marker
    • colors (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the color of each sector of this pie chart. If not specified, the default trace color set is used to pick the sector colors.
    • line
      • color (color)
        default: "#444"
        Sets the color of the line enclosing each sector.
      • width (number greater than or equal to 0)
        default: 0
        Sets the width (in px) of the line enclosing each sector.
      • colorsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
      • widthsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for width . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's width data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • colorssrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for colors . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's colors data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • text (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets text elements associated with each sector. If trace `textinfo` contains a "text" flag, these elements will seen on the chart. If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
  • hovertext (string)
    default: ""
    Sets hover text elements associated with each sector. If a single string, the same string appears for all data points. If an array of string, the items are mapped in order of this trace's sectors. To be seen, trace `hoverinfo` must contain a "text" flag.
  • scalegroup (string)
    default: ""
    If there are multiple pies that should be sized according to their totals, link them by providing a non-empty group id here shared by every trace in the same group.
  • textinfo (flaglist string)
    Any combination of "label", "text", "value", "percent" joined with a "+" OR "none".
    examples: "label", "text", "label+text", "label+text+value", "none"
    Determines which trace information appear on the graph.
  • textposition (enumerated: "inside" | "outside" | "auto" | "none" )
    default: "auto"
    Specifies the location of the `textinfo`.
  • textfont
    Sets the font used for `textinfo`.
    • family (string)
      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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
    • color (color)
  • insidetextfont
    Sets the font used for `textinfo` lying inside the pie.
    • family (string)
      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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
    • color (color)
  • outsidetextfont
    Sets the font used for `textinfo` lying outside the pie.
    • family (string)
      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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
    • color (color)
  • domain
    • x (list)
      default: [0, 1]
      Sets the horizontal domain of this pie trace (in plot fraction).
      Each dict has one or more of the keys listed below.
    • y (list)
      default: [0, 1]
      Sets the vertical domain of this pie trace (in plot fraction).
      Each dict has one or more of the keys listed below.
  • hole (number between or equal to 0 and 1)
    default: 0
    Sets the fraction of the radius to cut out of the pie. Use this to make a donut chart.
  • sort (boolean)
    default: True
    Determines whether or not the sectors are reordered from largest to smallest.
  • direction (enumerated: "clockwise" | "counterclockwise" )
    default: "counterclockwise"
    Specifies the direction at which succeeding sectors follow one another.
  • rotation (number between or equal to -360 and 360)
    default: 0
    Instead of the first slice starting at 12 o'clock, rotate to some other angle.
  • pull (number between or equal to 0 and 1)
    default: 0
    Sets the fraction of larger radius to pull the sectors out from the center. This can be a constant to pull all slices apart from each other equally or an array to highlight one or more slices.
  • labelssrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for labels . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's labels data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • valuessrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for values . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's values data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for text . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's text data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • hovertextsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for hovertext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's hovertext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textpositionsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for textposition . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's textposition data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • pullsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for pull . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's pull data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.

contour

import plotly.graph_objs as go
go.Contour
A Contour trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "x", "y", "z", "text", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "x", "y", "x+y", "x+y+z", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • z (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the z data.
  • x (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the x coordinates.
  • x0 (number or categorical coordinate string)
    default: 0
    Alternate to `x`. Builds a linear space of x coordinates. Use with `dx` where `x0` is the starting coordinate and `dx` the step.
  • dx (number)
    default: 1
    Sets the x coordinate step. See `x0` for more info.
  • y (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the y coordinates.
  • y0 (number or categorical coordinate string)
    default: 0
    Alternate to `y`. Builds a linear space of y coordinates. Use with `dy` where `y0` is the starting coordinate and `dy` the step.
  • dy (number)
    default: 1
    Sets the y coordinate step. See `y0` for more info.
  • text (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the text elements associated with each z value.
  • transpose (boolean)
    Transposes the z data.
  • xtype (enumerated: "array" | "scaled" )
    If "array", the heatmap's x coordinates are given by "x" (the default behavior when `x` is provided). If "scaled", the heatmap's x coordinates are given by "x0" and "dx" (the default behavior when `x` is not provided).
  • ytype (enumerated: "array" | "scaled" )
    If "array", the heatmap's y coordinates are given by "y" (the default behavior when `y` is provided) If "scaled", the heatmap's y coordinates are given by "y0" and "dy" (the default behavior when `y` is not provided)
  • connectgaps (boolean)
    Determines whether or not gaps (i.e. {nan} or missing values) in the `z` data are filled in.
  • autocontour (boolean)
    default: True
    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 in `contours`.
  • ncontours (integer greater than or equal to 1)
    default: 15
    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 if `autocontour` is "True" or if `contours.size` is missing.
  • contours
    • start (number)
      Sets the starting contour level value. Must be less than `contours.end`
    • end (number)
      Sets the end contour level value. Must be more than `contours.start`
    • size (number greater than or equal to 0)
      Sets the step between each contour level. Must be positive.
    • coloring (enumerated: "fill" | "heatmap" | "lines" | "none" )
      default: "fill"
      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.
    • showlines (boolean)
      default: True
      Determines whether or not the contour lines are drawn. Has only an effect if `contours.coloring` is set to "fill".
  • line
    • color (color)
      Sets the color of the contour level. Has no if `contours.coloring` is set to "lines".
    • width (number greater than or equal to 0)
      default: 2
      Sets the line width (in px).
    • dash (string)
      default: "solid"
      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 (number between or equal to 0 and 1.3)
      default: 1
      Sets the amount of smoothing for the contour lines, where "0" corresponds to no smoothing.
  • zauto (boolean)
    default: True
    Determines the whether or not the color domain is computed with respect to the input data.
  • zmin (number)
    Sets the lower bound of color domain.
  • zmax (number)
    Sets the upper bound of color domain.
  • colorscale (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 z space, use zmin and zmax
  • autocolorscale (boolean)
    Determines whether or not the colorscale is picked using the sign of the input z values.
  • reversescale (boolean)
    Reverses the colorscale.
  • showscale (boolean)
    default: True
    Determines whether or not a colorbar is displayed for this trace.
  • colorbar
    • thicknessmode (enumerated: "fraction" | "pixels" )
      default: "pixels"
      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 `thickness` to set the value.
    • thickness (number greater than or equal to 0)
      default: 30
      Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
    • lenmode (enumerated: "fraction" | "pixels" )
      default: "fraction"
      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 `len` to set the value.
    • len (number greater than or equal to 0)
      default: 1
      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.
    • x (number between or equal to -2 and 3)
      default: 1.02
      Sets the x position of the color bar (in plot fraction).
    • xanchor (enumerated: "left" | "center" | "right" )
      default: "left"
      Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the "left", "center" or "right" of the color bar.
    • xpad (number greater than or equal to 0)
      default: 10
      Sets the amount of padding (in px) along the x direction.
    • y (number between or equal to -2 and 3)
      default: 0.5
      Sets the y position of the color bar (in plot fraction).
    • yanchor (enumerated: "top" | "middle" | "bottom" )
      default: "middle"
      Sets this color bar's vertical position anchor This anchor binds the `y` position to the "top", "middle" or "bottom" of the color bar.
    • ypad (number greater than or equal to 0)
      default: 10
      Sets the amount of padding (in px) along the y direction.
    • outlinecolor (color)
      default: "#444"
      Sets the axis line color.
    • outlinewidth (number greater than or equal to 0)
      default: 1
      Sets the width (in px) of the axis line.
    • bordercolor (color)
      default: "#444"
      Sets the axis line color.
    • borderwidth (number greater than or equal to 0)
      default: 0
      Sets the width (in px) or the border enclosing this color bar.
    • bgcolor (color)
      default: "rgba(0,0,0,0)"
      Sets the color of padded area.
    • tickmode (enumerated: "auto" | "linear" | "array" )
      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 position `tick0` and a tick step `dtick` ("linear" is the default value if `tick0` and `dtick` are provided). If "array", the placement of the ticks is set via `tickvals` and the tick text is `ticktext`. ("array" is the default value if `tickvals` is provided).
    • nticks (integer greater than or equal to 0)
      default: 0
      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 if `tickmode` is set to "auto".
    • tick0 (number or categorical coordinate string)
      Sets the placement of the first tick on this axis. Use with `dtick`. If the axis `type` is "log", then you must take the log of your starting tick (e.g. to set the starting tick to 100, set the `tick0` to 2) except when `dtick`="L<f>" (see `dtick` for more info). If the axis `type` is "date", it should be a date string, like date data. If the axis `type` is "category", it should be a number, using the scale where each category is assigned a serial number from zero in the order it appears.
    • dtick (number or categorical coordinate string)
      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 axis `type` is "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>", where `f` is a positive number, gives ticks linearly spaced in value (but not position). For example `tick0` = 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). `tick0` is ignored for "D1" and "D2". If the axis `type` is "date", then you must convert the time to milliseconds. For example, to set the interval between ticks to one day, set `dtick` to 86400000.0. "date" also has special values "M<n>" gives ticks spaced by a number of months. `n` must be a positive integer. To set ticks on the 15th of every third month, set `tick0` to "2000-01-15" and `dtick` to "M3". To set ticks every 4 years, set `dtick` to "M48"
    • tickvals (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the values at which ticks on this axis appear. Only has an effect if `tickmode` is set to "array". Used with `ticktext`.
    • ticktext (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
      Sets the text displayed at the ticks position via `tickvals`. Only has an effect if `tickmode` is set to "array". Used with `tickvals`.
    • ticks (enumerated: "outside" | "inside" | "" )
      default: ""
      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.
    • ticklen (number greater than or equal to 0)
      default: 5
      Sets the tick length (in px).
    • tickwidth (number greater than or equal to 0)
      default: 1
      Sets the tick width (in px).
    • tickcolor (color)
      default: "#444"
      Sets the tick color.
    • showticklabels (boolean)
      default: True
      Determines whether or not the tick labels are drawn.
    • tickfont
      Sets the tick font.
      • family (string)
        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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
      • color (color)
    • tickangle (angle)
      default: auto
      Sets the angle of the tick labels with respect to the horizontal. For example, a `tickangle` of -90 draws the tick labels vertically.
    • tickformat (string)
      default: ""
      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-format/blob/master/README.md#locale_format And for dates see: https://github.com/d3/d3-time-format/blob/master/README.md#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"
    • tickprefix (string)
      default: ""
      Sets a tick label prefix.
    • showtickprefix (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      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.
    • ticksuffix (string)
      default: ""
      Sets a tick label suffix.
    • showticksuffix (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      Same as `showtickprefix` but for tick suffixes.
    • separatethousands (boolean)
      If "True", even 4-digit integers are separated
    • exponentformat (enumerated: "none" | "e" | "E" | "power" | "SI" | "B" )
      default: "B"
      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.
    • showexponent (enumerated: "all" | "first" | "last" | "none" )
      default: "all"
      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.
    • title (string)
      default: "Click to enter colorscale title"
      Sets the title of the color bar.
    • titlefont
      Sets this color bar's title font.
      • family (string)
        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 plotly service (at https://plot.ly 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 (number greater than or equal to 1)
      • color (color)
    • titleside (enumerated: "right" | "top" | "bottom" )
      default: "top"
      Determines the location of the colorbar title with respect to the color bar.
    • tickvalssrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for tickvals . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's tickvals data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • ticktextsrc (source string | plotly.grid_objs.Column)
      Sets the source reference on plot.ly for ticktext . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's ticktext data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xaxis (subplotid)
    default: x
    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 to `layout.xaxis2`, and so on.
  • yaxis (subplotid)
    default: y
    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 to `layout.xaxis2`, and so on.
  • xcalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `x` date data.
  • ycalendar (enumerated: "gregorian" | "chinese" | "coptic" | "discworld" | "ethiopian" | "hebrew" | "islamic" | "julian" | "mayan" | "nanakshahi" | "nepali" | "persian" | "jalali" | "taiwan" | "thai" | "ummalqura" )
    default: "gregorian"
    Sets the calendar system to use with `y` date data.
  • zsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for z . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's z data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • xsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for x . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's x data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • ysrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for y . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's y data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
  • textsrc (source string | plotly.grid_objs.Column)
    Sets the source reference on plot.ly for text . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's text data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.

scatterternary

import plotly.graph_objs as go
go.Scatterternary
A Scatterternary trace is a graph object with any of the named arguments or attributes listed below.



  • visible (enumerated: True | False | "legendonly" )
    default: True
    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).
  • showlegend (boolean)
    default: True
    Determines whether or not an item corresponding to this trace is shown in the legend.
  • legendgroup (string)
    default: ""
    Sets the legend group for this trace. Traces part of the same legend group hide/show at the same time when toggling legend items.
  • opacity (number between or equal to 0 and 1)
    default: 1
    Sets the opacity of the trace.
  • name (string)
    Sets the trace name. The trace name appear as the legend item and on hover.
  • hoverinfo (flaglist string)
    Any combination of "a", "b", "c", "text", "name" joined with a "+" OR "all" or "none" or "skip".
    examples: "a", "b", "a+b", "a+b+c", "all"
    default: "all"
    Determines which trace information appear on hover. If `none` or `skip` are set, no information is displayed upon hovering. But, if `none` is set, click and hover events are still fired.
  • stream
    • token (string)
      The stream id number links a data trace on a plot with a stream. See https://plot.ly/settings for more details.
    • maxpoints (number between or equal to 0 and 10000)
      default: 500
      Sets the maximum number of points to keep on the plots from an incoming stream. If `maxpoints` is set to "50", only the newest 50 points will be displayed on the plot.
  • a (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the quantity of component `a` in each data point. If `a`, `b`, and `c` are all provided, they need not be normalized, only the relative values matter. If only two arrays are provided they must be normalized to match `ternary<i>.sum`.
  • b (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the quantity of component `a` in each data point. If `a`, `b`, and `c` are all provided, they need not be normalized, only the relative values matter. If only two arrays are provided they must be normalized to match `ternary<i>.sum`.
  • c (list, numpy array, or Pandas series of numbers, strings, or datetimes.)
    Sets the quantity of component `a` in each data point. If `a`, `b`, and `c` are all provided, they need not be normalized, only the relative values matter. If only two arrays are provided they must be normalized to match `ternary<i>.sum`.
  • sum (number greater than or equal to 0)
    default: 0
    The number each triplet should sum to, if only two of `a`, `b`, and `c` are provided. This overrides `ternary<i>.sum` to normalize this specific trace, but does not affect the values displayed on the axes. 0 (or missing) means to use ternary<i>.sum
  • mode (flaglist string)
    Any combination of "lines", "markers", "text" joined with a "+" OR "none".
    examples: "lines", "markers", "lines+markers", "lines+markers+text", "none"
    default: "markers"
    Determines the drawing mode for this scatter trace. If the provided `mode` includes "text" then the `text` elements appear at the coordinates. Otherwise, the `text` elements appear on hover. If there are less than 20 points, then the default is "lines+markers". Otherwise, "lines".
  • text (string)
    default: ""
    Sets text elements associated with each (a,b,c) point. If a single string, the same string appears over all the data points. If an array of strings, the items are mapped in order to the the data points in (a,b,c). If trace `hoverinfo` contains a "text" flag and "hovertext" is not set, these elements will be seen in the hover labels.
  • hovertext (string)
    default: ""
    Sets hover text elements associated with each (a,b,c) point. If a single string, the same string appears over all the data points. If an array of strings, the items are mapped in order to the the data points in (a,b,c). To be seen, trace `hoverinfo` must contain a "text" flag.
  • line
    • color (color)
      Sets the line color.
    • width (number greater than or equal to 0)
      default: 2
      Sets the line width (in px).
    • dash (string)
      default: "solid"
      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").
    • shape (enumerated: "linear" | "spline" )
      default: "linear"
      Determines the line shape. With "spline" the lines are drawn using spline interpolation. The other available values correspond to step-wise line shapes.
    • smoothing (number between or equal to 0 and 1.3)
      default: 1
      Has an effect only if `shape` is set to "spline" Sets the amount of smoothing. "0" corresponds to no smoothing (equivalent to a "linear" shape).
  • connectgaps (boolean)
    Determines whether or not gaps (i.e. {nan} or missing values) in the provided data arrays are connected.
  • fill (enumerated: "none" | "toself" | "tonext" )
    default: "none"
    Sets the area to fill with a solid color. Use with `fillcolor` if not "none". scatterternary has a subset of the options available to scatter. "toself" connects the endpoints of the trace (or each segment of the trace if it has gaps) into a closed shape. "tonext" fills the space between two traces if one completely encloses the other (eg consecutive contour lines), and behaves like "toself" if there is no trace before it. "tonext" should not be used if one trace does not enclose the other.
  • fillcolor (color)
    Sets the fill color. Defaults to a half-transparent variant of the line color, marker color, or marker line color, whichever is available.
  • marker
    • symbol (enumerated: "0" | "circle" | "100" | "circle-open" | "200" | "circle-dot" | "300" | "circle-open-dot" | "1" | "square" | "101" | "square-open" | "201" | "square-dot" | "301" | "square-open-dot" | "2" | "diamond" | "102" | "diamond-open" | "202" | "diamond-dot" | "302" | "diamond-open-dot" | "3" | "cross" | "103" | "cross-open" | "203" | "cross-dot" | "303" | "cross-open-dot" | "4" | "x" | "104" | "x-open" | "204" | "x-dot" | "304" | "x-open-dot" | "5" | "triangle-up" | "105" | "triangle-up-open" | "205" | "triangle-up-dot" | "305" | "triangle-up-open-dot" | "6" | "triangle-down" | "106" | "triangle-down-open" | "206" | "triangle-down-dot" | "306" | "triangle-down-open-dot" | "7" | "triangle-left" | "107" | "triangle-left-open" | "207" | "triangle-left-dot" | "307" | "triangle-left-open-dot" | "8" | "triangle-right" | "108" | "triangle-right-open" | "208" | "triangle-right-dot" | "308" | "triangle-right-open-dot" | "9" | "triangle-ne" | "109" | "triangle-ne-open" | "209" | "triangle-ne-dot" | "309" | "triangle-ne-open-dot" | "10" | "triangle-se" | "110" | "triangle-se-open" | "210" | "triangle-se-dot" | "310" | "triangle-se-open-dot" | "11" | "triangle-sw" | "111" | "triangle-sw-open" | "211" | "triangle-sw-dot" | "311" | "triangle-sw-open-dot" | "12" | "triangle-nw" | "112" | "triangle-nw-open" | "212" | "triangle-nw-dot" | "312" | "triangle-nw-open-dot" | "13" | "pentagon" | "113" | "pentagon-open" | "213" | "pentagon-dot" | "313" | "pentagon-open-dot" | "14" | "hexagon" | "114" | "hexagon-open" | "214" | "hexagon-dot" | "314" | "hexagon-open-dot" | "15" | "hexagon2" | "115" | "hexagon2-open" | "215" | "hexagon2-dot" | "315" | "hexagon2-open-dot" | "16" | "octagon" | "116" | "octagon-open" | "216" | "octagon-dot" | "316" | "octagon-open-dot" | "17" | "star" | "117" | "star-open" | "217" | "star-dot" | "317" | "star-open-dot" | "18" | "hexagram" | "118" | "hexagram-open" | "218" | "hexagram-dot" | "318" | "hexagram-open-dot" | "19" | "star-triangle-up" | "119" | "star-triangle-up-open" | "219" | "star-triangle-up-dot" | "319" | "star-triangle-up-open-dot" | "20" | "star-triangle-down" | "120" | "star-triangle-down-open" | "220" | "star-triangle-down-dot" | "320" | "star-triangle-down-open-dot" | "21" | "star-square" | "121" | "star-square-open" | "221" | "star-square-dot" | "321" | "star-square-open-dot" | "22" | "star-diamond" | "122" | "star-diamond-open" | "222" | "star-diamond-dot" | "322" | "star-diamond-open-dot" | "23" | "diamond-tall" | "123" | "diamond-tall-open" | "223" | "diamond-tall-dot" | "323" | "diamond-tall-open-dot" | "24" | "diamond-wide" | "124" | "diamond-wide-open" | "224" | "diamond-wide-dot" | "324" | "diamond-wide-open-dot" | "25" | "hourglass" | "125" | "hourglass-open" | "26" | "bowtie" | "126" | "bowtie-open" | "27" | "circle-cross" | "127" | "circle-cross-open" | "28" | "circle-x" | "128" | "circle-x-open" | "29" | "square-cross" | "129" | "square-cross-open" | "30" | "square-x" | "130" | "square-x-open" | "31" | "diamond-cross" | "131" | "diamond-cross-open" | "32" | "diamond-x" | "132" | "diamond-x-open" | "33" | "cross-thin" | "133" | "cross-thin-open" | "34" | "x-thin" | "134" | "x-thin-open" | "35" | "asterisk" | "135" | "asterisk-open" | "36" | "hash" | "136" | "hash-open" | "236" | "hash-dot" | "336" | "hash-open-dot" | "37" | "y-up" | "137" | "y-up-open" | "38" | "y-down" | "138" | "y-down-open" | "39" | "y-left" | "139" | "y-left-open" | "40" | "y-right" | "140" | "y-right-open" | "41" | "line-ew" | "141" | "line-ew-open" | "42" | "line-ns" | "142" | "line-ns-open" | "43" | "line-ne" | "143" | "line-ne-open" | "44" | "line-nw" | "144" | "line-nw-open" )
      default: "circle"
      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.
    • opacity (number between or equal to 0 and 1)
      Sets the marker opacity.
    • maxdisplayed (number greater than or equal to 0)
      default: 0
      Sets a maximum number of points to be drawn on the graph. "0" corresponds to no limit.
    • size (number greater than or equal to 0)
      default: 6
      Sets the marker size (in px).
    • sizeref (number)
      default: 1
      Has an effect only if `marker.size` is set to a numerical array. Sets the scale factor used to determine the rendered size of marker points. Use with `sizemin` and `sizemode`.
    • sizemin (number greater than or equal to 0)
      default: 0
      Has an effect only if `marker.size` is set to a numerical array. Sets the minimum size (in px) of the rendered marker points.
    • sizemode (enumerated: "diameter" | "area" )
      default: "diameter"
      Has an effect only if `marker.size` is set to a numerical array. Sets the rule for which the data in `size` is converted to pixels.
    • line
      • width (number greater than or equal to 0)
        Sets the width (in px) of the lines bounding the marker points.
      • color (color)
        Sets the color. 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 `cmin` and `cmax` if set.
      • colorscale (colorscale)
        Sets the colorscale and only has an effect if `.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 `.cmin` and `.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Greys, YlGnBu, Greens, YlOrRd, Bluered, RdBu, Reds, Blues, Picnic, Rainbow, Portland, Jet, Hot, Blackbody, Earth, Electric, Viridis
      • cauto (boolean)
        default: True
        Has an effect only if `.color` is set to a numerical array and `cmin`, `cmax` are set by the user. In this case, it controls whether the range of colors in `colorscale` is mapped to the range of values in the `color` array (`cauto: True`), or the `cmin`/`cmax` values (`cauto: False`). Defaults to `False` when `cmin`, `cmax` are set by the user.
      • cmax (number)
        Has an effect only if `.color` is set to a numerical array. Sets the upper bound of the color domain. Value should be associated to the `.color` array index, and if set, `.cmin` must be set as well.
      • cmin (number)
        Has an effect only if `.color` is set to a numerical array. Sets the lower bound of the color domain. Value should be associated to the `.color` array index, and if set, `.cmax` must be set as well.
      • autocolorscale (boolean)
        default: True
        Has an effect only if `.color` is set to a numerical array. Determines whether the colorscale is a default palette (`autocolorscale: True`) or the palette determined by `.colorscale`. In case `colorscale` is unspecified or `autocolorscale` is True, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
      • reversescale (boolean)
        Has an effect only if `.color` is set to a numerical array. Reverses the color mapping if True (`cmin` will correspond to the last color in the array and `cmax` will correspond to the first color).
      • widthsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for width . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's width data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
      • colorsrc (source string | plotly.grid_objs.Column)
        Sets the source reference on plot.ly for color . A source string refers to a unique identifier that is assigned to a plotly grid. Assigning data to a graph with a source string is an alternative way to set this graph's color data. It's useful if you want to keep your data separate from your graphs, create several graphs from a single dataset, or edit your graph's data after creation. Learn more.
    • color (color)
      Sets the marker color. 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 `cmin` and `cmax` if set.
    • colorscale (colorscale)
      Sets the colorscale and only has an effect if `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` and `marker.cmax`. Alternatively, `colorscale` may be a palette name string of the following list: Greys, YlGnBu, Greens, YlOrRd, Bluered, RdBu, Reds, Blues, Picnic, Rainbow, Portland, Jet, Hot, Blackbody, Earth, Electric, Viridis
    • cauto (boolean)
      default: True
      Has an effect only if `marker.color` is set to a numerical array and `cmin`, `cmax` are set by the user. In this case, it controls whether the range of colors in `colorscale` is mapped to the range of values in the `color` array (`cauto: True`), or the `cmin`/`cmax` values (`cauto: False`). Defaults to `False` when `cmin`, `cmax` are set by the user.
    • cmax (number)
      Has an effect only if `marker.color` is set to a numerical array. Sets the upper bound of the color domain. Value should be associated to the `marker.color` array index, and if set, `marker.cmin` must be set as well.
    • cmin (number)
      Has an effect only if `marker.color` is set to a numerical array. Sets the lower bound of the color domain. Value should be associated to the `marker.color` array index, and if set, `marker.cmax` must be set as well.
    • autocolorscale (boolean)
      default: True
      Has an effect only if `marker.color` is set to a numerical array. Determines whether the colorscale is a default palette (`autocolorscale: True`) or the palette determined by `marker.colorscale`. In case `colorscale` is unspecified or `autocolorscale` is True, the default palette will be chosen according to whether numbers in the `color` array are all positive, all negative or mixed.
    • reversescale (boolean)
      Has an effect only if `marker.color` is set to a numerical array. Reverses the color mapping if True (`cmin` will correspond to the last color in the array and `cmax` will correspond to the first color).
    • showscale (boolean)
      Has an effect only if `marker.color` is set to a numerical array. Determines whether or not a colorbar is displayed.
    • colorbar
      • thicknessmode (enumerated: "fraction" | "pixels" )
        default: "pixels"
        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 `thickness` to set the value.
      • thickness (number greater than or equal to 0)
        default: 30
        Sets the thickness of the color bar This measure excludes the size of the padding, ticks and labels.
      • lenmode (enumerated: "fraction" | "pixels" )
        default: "fraction"
        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 `len` to set the value.
      • len (number greater than or equal to 0)
        default: 1
        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.
      • x (number between or equal to -2 and 3)
        default: 1.02
        Sets the x position of the color bar (in plot fraction).
      • xanchor (enumerated: "left" | "center" | "right" )
        default: "left"
        Sets this color bar's horizontal position anchor. This anchor binds the `x` position to the "left", "center" or "right" of the color bar.
      • xpad (number greater than or equal to 0)
        default: 10
        Sets the amount of padding (in px) along the x direction.
      • y (number between or equal to -2 and 3)
        default: 0.5
        Sets the y position of the color bar (in plot fraction).
      • yanchor (enumerated: "top" | "middle" | "bottom" )
        default: "middle"
        Sets this color bar's vertical position anchor This anchor binds the `y` position to the "top", "middle" or "bottom" of the color bar.
      • ypad (number greater than or equal to 0)
        default: 10
        Sets the amount of padding (in px) along the y direction.
      • outlinecolor (