If the data contains strings, the color will automatically be considered discrete (also known as categorical or qualitative). Most Plotly Express functions accept a color argument which automatically assigns data values to continuous color if the data is numeric. marker.showscale whereas shared color axis attributes are configured within the Layout e.g. Local color axis attributes are configured within traces e.g. loraxis in go.Scatter traces or coloraxis in go.Heatmap traces. By default, any colorable attribute in a trace is attached to its own local color axis, but color axes may also be shared across attributes and traces by setting e.g. color axes connect color scales, color ranges and color bars to a trace's data.Color bars can be configured with attributes inside or in places like lorbar in go.Scatter traces or colorbar in go.Heatmap traces. color bars are legend-like visible representations of the color range and color scale with optional tick labels and tick marks.Marks with values in between will be various shades of purple. For example, if a color range of is used with the color scale above, then any mark with a color value of 100 or less will be blue, and 200 or more will be red. Color ranges default to the range of the input data and can be explicitly specified using either the range_color or color_continuous_midpoint arguments for many Plotly Express functions, or cmin/ cmid/ cmax or zmin/ zmid/ zmax for various graph_objects such as or marker.cmin in go.Scatter traces or cmin in go.Heatmap traces. color ranges represent the minimum to maximum range of data to be mapped onto the 0 to 1 input range of the color scale.For example is a simple color scale that interpolated between blue and red via purple, which can also be implicitly represented as and happens to be one of the built-in color scales and therefore referred to as "bluered" or. Color scale defaults depend on the lorscales attributes of the active template, and can be explicitly specified using the color_continuous_scale argument for many Plotly Express functions or the colorscale argument in various graph_objects such as loraxis or lorscale in go.Scatter traces or colorscale in go.Heatmap traces. color scales represent a mapping between the range 0 to 1 and some color domain within which colors are to be interpolated (unlike discrete color sequences which are never interpolated).This document explains the following four continuous-color-related concepts: This page is about using color to represent continuous data, but Plotly can also represent categorical values with color. labels), color can be used to represent continuous or categorical data. amounts or moments in time) or categories (i.e. In the same way as the X or Y position of a mark in cartesian coordinates can be used to represent continuous values (i.e.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |