holoviews.plotting.mpl.element module#
- class holoviews.plotting.mpl.element.ColorbarPlot(*args, **kwargs)[source]#
Bases:
ElementPlot
Parameter Definitions
Parameters inherited from:
holoviews.plotting.plot.DimensionedPlot
: fontsize, fontscale, show_title, title, normalizeholoviews.plotting.mpl.plot.MPLPlot
: projection, backend_opts, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_offset, sublabel_position, sublabel_size, sublabel_skip, show_frameholoviews.plotting.plot.GenericElementPlot
: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticksholoviews.plotting.mpl.element.ElementPlot
: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticksclabel = String(allow_None=True, label='Clabel')
An explicit override of the color bar label, if set takes precedence over the title key in colorbar_opts.
clim = Tuple(default=(nan, nan), label='Clim', length=2)
User-specified colorbar axis range limits for the plot, as a tuple (low,high). If specified, takes precedence over data and dimension ranges.
clim_percentile = ClassSelector(class_=(<class 'int'>, <class 'float'>, <class 'bool'>), default=False, label='Clim percentile')
Percentile value to compute colorscale robust to outliers. If True, uses 2nd and 98th percentile; otherwise uses the specified numerical percentile value.
cformatter = ClassSelector(allow_None=True, class_=(<class 'str'>, <class 'matplotlib.ticker.Formatter'>, <class 'function'>), label='Cformatter')
Formatter for ticks along the colorbar axis.
colorbar = Boolean(default=False, label='Colorbar')
Whether to draw a colorbar.
colorbar_opts = Dict(class_=<class 'dict'>, default={}, label='Colorbar opts')
Allows setting specific styling options for the colorbar.
color_levels = ClassSelector(allow_None=True, class_=(<class 'int'>, <class 'list'>), label='Color levels')
Number of discrete colors to use when colormapping or a set of color intervals defining the range of values to map each color to.
cnorm = Selector(default='linear', label='Cnorm', names={}, objects=['linear', 'log', 'eq_hist'])
Color normalization to be applied during colormapping.
clipping_colors = Dict(class_=<class 'dict'>, default={}, label='Clipping colors')
Dictionary to specify colors for clipped values, allows setting color for NaN values and for values above and below the min and max value. The min, max or NaN color may specify an RGB(A) color as a color hex string of the form #FFFFFF or #FFFFFFFF or a length 3 or length 4 tuple specifying values in the range 0-1 or a named HTML color.
cbar_padding = Number(default=0.01, inclusive_bounds=(True, True), label='Cbar padding')
Padding between colorbar and other plots.
cbar_ticks = Parameter(allow_None=True, label='Cbar ticks')
Ticks along colorbar-axis specified as an integer, explicit list of tick locations, list of tuples containing the locations and labels or a matplotlib tick locator object. If set to None default matplotlib ticking behavior is applied.
cbar_width = Number(default=0.05, inclusive_bounds=(True, True), label='Cbar width')
Width of the colorbar as a fraction of the main plot
cbar_extend = Selector(label='Cbar extend', names={}, objects=['neither', 'both', 'min', 'max'])
If not ‘neither’, make pointed end(s) for out-of- range values.
rescale_discrete_levels = Boolean(default=True, label='Rescale discrete levels')
If
cnorm='eq_hist
and there are only a few discrete values, thenrescale_discrete_levels=True
decreases the lower limit of the autoranged span so that the values are rendering towards the (more visible) top of the palette, thus avoiding washout of the lower values. Has no effect ifcnorm!=`eq_hist
. Set this value to False if you need to match historical unscaled behavior, prior to HoloViews 1.14.4.symmetric = Boolean(default=False, label='Symmetric')
Whether to make the colormap symmetric around zero.
- class holoviews.plotting.mpl.element.ElementPlot(element, **params)[source]#
Bases:
GenericElementPlot
,MPLPlot
Parameter Definitions
Parameters inherited from:
holoviews.plotting.plot.DimensionedPlot
: fontsize, fontscale, show_title, title, normalizeholoviews.plotting.mpl.plot.MPLPlot
: projection, backend_opts, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_offset, sublabel_position, sublabel_size, sublabel_skip, show_frameholoviews.plotting.plot.GenericElementPlot
: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticksapply_ticks = Boolean(default=True, label='Apply ticks')
Whether to apply custom ticks.
aspect = Parameter(default='square', label='Aspect')
The aspect ratio mode of the plot. By default, a plot may select its own appropriate aspect ratio but sometimes it may be necessary to force a square aspect ratio (e.g. to display the plot as an element of a grid). The modes ‘auto’ and ‘equal’ correspond to the axis modes of the same name in matplotlib, a numeric value specifying the ratio between plot width and height may also be passed. To control the aspect ratio between the axis scales use the data_aspect option instead.
data_aspect = Number(allow_None=True, inclusive_bounds=(True, True), label='Data aspect')
Defines the aspect of the axis scaling, i.e. the ratio of y-unit to x-unit.
invert_zaxis = Boolean(default=False, label='Invert zaxis')
Whether to invert the plot z-axis.
labelled = List(bounds=(0, None), default=['x', 'y'], label='Labelled')
Whether to plot the ‘x’ and ‘y’ labels.
logz = Boolean(default=False, label='Logz')
Whether to apply log scaling to the y-axis of the Chart.
xformatter = ClassSelector(allow_None=True, class_=(<class 'str'>, <class 'matplotlib.ticker.Formatter'>, <class 'function'>), label='Xformatter')
Formatter for ticks along the x-axis.
yformatter = ClassSelector(allow_None=True, class_=(<class 'str'>, <class 'matplotlib.ticker.Formatter'>, <class 'function'>), label='Yformatter')
Formatter for ticks along the y-axis.
zformatter = ClassSelector(allow_None=True, class_=(<class 'str'>, <class 'matplotlib.ticker.Formatter'>, <class 'function'>), label='Zformatter')
Formatter for ticks along the z-axis.
zaxis = Boolean(default=True, label='Zaxis')
Whether to display the z-axis.
zlabel = String(allow_None=True, label='Zlabel')
An explicit override of the z-axis label, if set takes precedence over the dimension label.
zrotation = Integer(bounds=(0, 360), default=0, inclusive_bounds=(True, True), label='Zrotation')
Rotation angle of the zticks.
zticks = Parameter(allow_None=True, label='Zticks')
Ticks along z-axis specified as an integer, explicit list of tick locations, list of tuples containing the locations and labels or a matplotlib tick locator object. If set to None default matplotlib ticking behavior is applied.
- init_artists(ax, plot_args, plot_kwargs)[source]#
Initializes the artist based on the plot method declared on the plot.
- teardown_handles()[source]#
If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.
- class holoviews.plotting.mpl.element.LegendPlot(element, **params)[source]#
Bases:
ElementPlot
Parameter Definitions
Parameters inherited from:
holoviews.plotting.plot.DimensionedPlot
: fontsize, fontscale, show_title, title, normalizeholoviews.plotting.mpl.plot.MPLPlot
: projection, backend_opts, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_offset, sublabel_position, sublabel_size, sublabel_skip, show_frameholoviews.plotting.plot.GenericElementPlot
: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticksholoviews.plotting.mpl.element.ElementPlot
: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticksshow_legend = Boolean(default=True, label='Show legend')
Whether to show legend for the plot.
legend_cols = Integer(allow_None=True, inclusive_bounds=(True, True), label='Legend cols')
Number of legend columns in the legend.
legend_labels = Dict(class_=<class 'dict'>, default={}, label='Legend labels')
A mapping that allows overriding legend labels.
legend_position = Selector(default='inner', label='Legend position', names={}, objects=['inner', 'right', 'bottom', 'top', 'left', 'best', 'top_right', 'top_left', 'bottom_left', 'bottom_right'])
Allows selecting between a number of predefined legend position options. The predefined options may be customized in the legend_specs class attribute. By default, ‘inner’, ‘right’, ‘bottom’, ‘top’, ‘left’, ‘best’, ‘top_right’, ‘top_left’, ‘bottom_right’ and ‘bottom_left’ are supported.
legend_opts = Dict(class_=<class 'dict'>, default={}, label='Legend opts')
Allows setting specific styling options for the colorbar.
- class holoviews.plotting.mpl.element.OverlayPlot(overlay, ranges=None, **params)[source]#
Bases:
LegendPlot
,GenericOverlayPlot
OverlayPlot supports compositors processing of Overlays across maps.
Parameter Definitions
Parameters inherited from:
holoviews.plotting.plot.DimensionedPlot
: fontsize, fontscale, show_title, title, normalizeholoviews.plotting.mpl.plot.MPLPlot
: projection, backend_opts, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_offset, sublabel_position, sublabel_size, sublabel_skip, show_frameholoviews.plotting.plot.GenericElementPlot
: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticksholoviews.plotting.plot.GenericOverlayPlot
: batched, legend_limit, style_groupingholoviews.plotting.mpl.element.ElementPlot
: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticksholoviews.plotting.mpl.element.LegendPlot
: show_legend, legend_cols, legend_labels, legend_position, legend_opts