holoviews.mpl Package


mpl Package

holoviews.plotting.mpl.set_style(key)[source]

Select a style by name, e.g. set_style(‘default’). To revert to the previous style use the key ‘unset’ or False.


annotation Module

Inheritance diagram of holoviews.plotting.mpl.annotation
class holoviews.plotting.mpl.annotation.ABLine2D(slope, intercept, *args, **kwargs)[source]

Bases: matplotlib.lines.Line2D

Draw a line based on its slope and y-intercept. Additional arguments are passed to the <matplotlib.lines.Line2D> constructor.

add_callback(func)

Adds a callback function that will be called whenever one of the Artist’s properties changes.

Returns an id that is useful for removing the callback with remove_callback() later.

property axes

The Axes instance the artist resides in, or None.

contains(mouseevent)

Test whether the mouse event occurred on the line. The pick radius determines the precision of the location test (usually within five points of the value). Use get_pickradius() or set_pickradius() to view or modify it.

Returns True if any values are within the radius along with {'ind': pointlist}, where pointlist is the set of points within the radius.

TODO: sort returned indices by distance

convert_xunits(x)

For artists in an axes, if the xaxis has units support, convert x using xaxis unit type

convert_yunits(y)

For artists in an axes, if the yaxis has units support, convert y using yaxis unit type

draw(renderer)

draw the Line with renderer unless visibility is False

findobj(match=None, include_self=True)

Find artist objects.

Recursively find all Artist instances contained in self.

match can be

  • None: return all objects contained in artist.

  • function with signature boolean = match(artist) used to filter matches

  • class instance: e.g., Line2D. Only return artists of class type.

If include_self is True (default), include self in the list to be checked for a match.

format_cursor_data(data)

Return cursor data string formatted.

get_aa(*args, **kwargs)

alias for get_antialiased

get_agg_filter()

Return filter function to be used for agg filter.

get_alpha()

Return the alpha value used for blending - not supported on all backends

get_animated()

Return the artist’s animated state

get_c(*args, **kwargs)

alias for get_color

get_children()

Return a list of the child Artist`s this :class:`Artist contains.

get_clip_box()

Return artist clipbox

get_clip_on()

Return whether artist uses clipping

get_clip_path()

Return artist clip path

get_contains()

Return the _contains test used by the artist, or None for default.

get_cursor_data(event)

Get the cursor data for a given event.

get_dash_capstyle()

Get the cap style for dashed linestyles

get_dash_joinstyle()

Get the join style for dashed linestyles

get_data(orig=True)

Return the xdata, ydata.

If orig is True, return the original data.

get_figure()

Return the .Figure instance the artist belongs to.

get_fillstyle()

return the marker fillstyle

get_gid()

Returns the group id.

get_in_layout()

Return boolean flag, True if artist is included in layout calculations.

E.g. /tutorials/intermediate/constrainedlayout_guide, .Figure.tight_layout(), and fig.savefig(fname, bbox_inches='tight').

get_label()

Get the label used for this artist in the legend.

get_ls(*args, **kwargs)

alias for get_linestyle

get_lw(*args, **kwargs)

alias for get_linewidth

get_markevery()

return the markevery setting

get_mec(*args, **kwargs)

alias for get_markeredgecolor

get_mew(*args, **kwargs)

alias for get_markeredgewidth

get_mfc(*args, **kwargs)

alias for get_markerfacecolor

get_mfcalt(*args, **kwargs)

alias for get_markerfacecoloralt

get_ms(*args, **kwargs)

alias for get_markersize

get_path()

Return the Path object associated with this line.

get_picker()

Return the picker object used by this artist.

get_pickradius()

return the pick radius used for containment tests

get_rasterized()

Return whether the artist is to be rasterized.

get_sketch_params()

Returns the sketch parameters for the artist.

sketch_params : tuple or None

A 3-tuple with the following elements:

  • scale: The amplitude of the wiggle perpendicular to the source line.

  • length: The length of the wiggle along the line.

  • randomness: The scale factor by which the length is shrunken or expanded.

May return None if no sketch parameters were set.

get_snap()

Returns the snap setting which may be:

  • True: snap vertices to the nearest pixel center

  • False: leave vertices as-is

  • None: (auto) If the path contains only rectilinear line segments, round to the nearest pixel center

Only supported by the Agg and MacOSX backends.

get_solid_capstyle()

Get the cap style for solid linestyles

get_solid_joinstyle()

Get the join style for solid linestyles

get_tightbbox(renderer)

Like Artist.get_window_extent, but includes any clipping.

renderer.RendererBase instance

renderer that will be used to draw the figures (i.e. fig.canvas.get_renderer())

bbox.BboxBase

containing the bounding box (in figure pixel co-ordinates).

get_transform()

Return the Transform instance used by this artist.

get_transformed_clip_path_and_affine()

Return the clip path with the non-affine part of its transformation applied, and the remaining affine part of its transformation.

get_url()

Returns the url.

get_visible()

Return the artist’s visiblity

get_window_extent(renderer)

Get the axes bounding box in display space. Subclasses should override for inclusion in the bounding box “tight” calculation. Default is to return an empty bounding box at 0, 0.

Be careful when using this function, the results will not update if the artist window extent of the artist changes. The extent can change due to any changes in the transform stack, such as changing the axes limits, the figure size, or the canvas used (as is done when saving a figure). This can lead to unexpected behavior where interactive figures will look fine on the screen, but will save incorrectly.

get_xdata(orig=True)

Return the xdata.

If orig is True, return the original data, else the processed data.

get_xydata()

Return the xy data as a Nx2 numpy array.

get_ydata(orig=True)

Return the ydata.

If orig is True, return the original data, else the processed data.

get_zorder()

Return the artist’s zorder.

have_units()

Return True if units are set on the x or y axes

hitlist(event)

Deprecated since version 2.2: The hitlist function was deprecated in Matplotlib 2.2 and will be removed in 3.1.

List the children of the artist which contain the mouse event event.

is_dashed()

return True if line is dashstyle

is_figure_set()

Deprecated since version 2.2: artist.figure is not None

Returns whether the artist is assigned to a .Figure.

is_transform_set()

Returns True if Artist has a transform explicitly set.

pchanged()

Fire an event when property changed, calling all of the registered callbacks.

pick(mouseevent)

Process pick event

each child artist will fire a pick event if mouseevent is over the artist and the artist has picker set

pickable()

Return True if Artist is pickable.

properties()

return a dictionary mapping property name -> value for all Artist props

remove()

Remove the artist from the figure if possible. The effect will not be visible until the figure is redrawn, e.g., with matplotlib.axes.Axes.draw_idle(). Call matplotlib.axes.Axes.relim() to update the axes limits if desired.

Note: relim() will not see collections even if the collection was added to axes with autolim = True.

Note: there is no support for removing the artist’s legend entry.

remove_callback(oid)

Remove a callback based on its id.

See also

add_callback()

For adding callbacks

set(**kwargs)

A property batch setter. Pass kwargs to set properties.

set_aa(*args, **kwargs)

alias for set_antialiased

set_agg_filter(filter_func)

Set the agg filter.

filter_funccallable

A filter function, which takes a (m, n, 3) float array and a dpi value, and returns a (m, n, 3) array.

set_alpha(alpha)

Set the alpha value used for blending - not supported on all backends.

alpha : float

set_animated(b)

Set the artist’s animation state.

b : bool

set_antialiased(b)

Set whether to use antialiased rendering.

b : bool

set_c(*args, **kwargs)

alias for set_color

set_clip_box(clipbox)

Set the artist’s clip .Bbox.

clipbox : .Bbox

set_clip_on(b)

Set whether artist uses clipping.

When False artists will be visible out side of the axes which can lead to unexpected results.

b : bool

set_clip_path(path, transform=None)

Set the artist’s clip path, which may be:

  • a Patch (or subclass) instance; or

  • a Path instance, in which case a Transform instance, which will be applied to the path before using it for clipping, must be provided; or

  • None, to remove a previously set clipping path.

For efficiency, if the path happens to be an axis-aligned rectangle, this method will set the clipping box to the corresponding rectangle and set the clipping path to None.

ACCEPTS: [(~matplotlib.path.Path, .Transform) | .Patch | None]

set_color(color)

Set the color of the line

color : color

set_contains(picker)

Replace the contains test used by this artist. The new picker should be a callable function which determines whether the artist is hit by the mouse event:

hit, props = picker(artist, mouseevent)

If the mouse event is over the artist, return hit = True and props is a dictionary of properties you want returned with the contains test.

picker : callable

set_dash_capstyle(s)

Set the cap style for dashed linestyles.

s : {‘butt’, ‘round’, ‘projecting’}

set_dash_joinstyle(s)

Set the join style for dashed linestyles.

s : {‘miter’, ‘round’, ‘bevel’}

set_dashes(seq)

Set the dash sequence, sequence of dashes with on off ink in points. If seq is empty or if seq = (None, None), the linestyle will be set to solid.

seq : sequence of floats (on/off ink in points) or (None, None)

set_data(*args)

Set the x and y data

ACCEPTS: 2D array (rows are x, y) or two 1D arrays

set_drawstyle(drawstyle)

Set the drawstyle of the plot

‘default’ connects the points with lines. The steps variants produce step-plots. ‘steps’ is equivalent to ‘steps-pre’ and is maintained for backward-compatibility.

drawstyle : {‘default’, ‘steps’, ‘steps-pre’, ‘steps-mid’, ‘steps-post’}

set_figure(fig)

Set the .Figure instance the artist belongs to.

fig : .Figure

set_fillstyle(fs)

Set the marker fill style; ‘full’ means fill the whole marker. ‘none’ means no filling; other options are for half-filled markers.

fs : {‘full’, ‘left’, ‘right’, ‘bottom’, ‘top’, ‘none’}

set_gid(gid)

Sets the (group) id for the artist.

gid : str

set_in_layout(in_layout)

Set if artist is to be included in layout calculations, E.g. /tutorials/intermediate/constrainedlayout_guide, .Figure.tight_layout(), and fig.savefig(fname, bbox_inches='tight').

in_layout : bool

set_label(s)

Set the label to s for auto legend.

sobject

s will be converted to a string by calling str.

set_linestyle(ls)

Set the linestyle of the line (also accepts drawstyles, e.g., 'steps--')

linestyle

description

'-' or 'solid'

solid line

'--' or 'dashed'

dashed line

'-.' or 'dashdot'

dash-dotted line

':' or 'dotted'

dotted line

'None'

draw nothing

' '

draw nothing

''

draw nothing

‘steps’ is equivalent to ‘steps-pre’ and is maintained for backward-compatibility.

Alternatively a dash tuple of the following form can be provided:

(offset, onoffseq),

where onoffseq is an even length tuple of on and off ink in points.

See also

set_drawstyle()

To set the drawing style (stepping) of the plot.

ls{‘-‘, ‘–’, ‘-.’, ‘:’, ‘’, (offset, on-off-seq), …}

The line style.

set_linewidth(w)

Set the line width in points

w : float

set_ls(*args, **kwargs)

alias for set_linestyle

set_lw(*args, **kwargs)

alias for set_linewidth

set_marker(marker)

Set the line marker.

marker: marker style

See ~matplotlib.markers for full description of possible arguments.

set_markeredgecolor(ec)

Set the marker edge color.

ec : color

set_markeredgewidth(ew)

Set the marker edge width in points.

ew : float

set_markerfacecolor(fc)

Set the marker face color.

fc : color

set_markerfacecoloralt(fc)

Set the alternate marker face color.

fc : color

set_markersize(sz)

Set the marker size in points.

sz : float

set_markevery(every)

Set the markevery property to subsample the plot when using markers.

e.g., if every=5, every 5-th marker will be plotted.

every: None or int or (int, int) or slice or List[int] or float or (float, float)

Which markers to plot.

  • every=None, every point will be plotted.

  • every=N, every N-th marker will be plotted starting with marker 0.

  • every=(start, N), every N-th marker, starting at point start, will be plotted.

  • every=slice(start, end, N), every N-th marker, starting at point start, up to but not including point end, will be plotted.

  • every=[i, j, m, n], only markers at points i, j, m, and n will be plotted.

  • every=0.1, (i.e. a float) then markers will be spaced at approximately equal distances along the line; the distance along the line between markers is determined by multiplying the display-coordinate distance of the axes bounding-box diagonal by the value of every.

  • every=(0.5, 0.1) (i.e. a length-2 tuple of float), the same functionality as every=0.1 is exhibited but the first marker will be 0.5 multiplied by the display-cordinate-diagonal-distance along the line.

Setting the markevery property will only show markers at actual data points. When using float arguments to set the markevery property on irregularly spaced data, the markers will likely not appear evenly spaced because the actual data points do not coincide with the theoretical spacing between markers.

When using a start offset to specify the first marker, the offset will be from the first data point which may be different from the first the visible data point if the plot is zoomed in.

If zooming in on a plot when using float arguments then the actual data points that have markers will change because the distance between markers is always determined from the display-coordinates axes-bounding-box-diagonal regardless of the actual axes data limits.

set_mec(*args, **kwargs)

alias for set_markeredgecolor

set_mew(*args, **kwargs)

alias for set_markeredgewidth

set_mfc(*args, **kwargs)

alias for set_markerfacecolor

set_mfcalt(*args, **kwargs)

alias for set_markerfacecoloralt

set_ms(*args, **kwargs)

alias for set_markersize

set_path_effects(path_effects)

Set the path effects.

path_effects : .AbstractPathEffect

set_picker(p)

Sets the event picker details for the line.

pfloat or callable[[Artist, Event], Tuple[bool, dict]]

If a float, it is used as the pick radius in points.

set_pickradius(d)

Set the pick radius used for containment tests.

dfloat

Pick radius, in points.

set_rasterized(rasterized)

Force rasterized (bitmap) drawing in vector backend output.

Defaults to None, which implies the backend’s default behavior.

rasterized : bool or None

set_sketch_params(scale=None, length=None, randomness=None)

Sets the sketch parameters.

scalefloat, optional

The amplitude of the wiggle perpendicular to the source line, in pixels. If scale is None, or not provided, no sketch filter will be provided.

lengthfloat, optional

The length of the wiggle along the line, in pixels (default 128.0)

randomnessfloat, optional

The scale factor by which the length is shrunken or expanded (default 16.0)

set_snap(snap)

Sets the snap setting which may be:

  • True: snap vertices to the nearest pixel center

  • False: leave vertices as-is

  • None: (auto) If the path contains only rectilinear line segments, round to the nearest pixel center

Only supported by the Agg and MacOSX backends.

snap : bool or None

set_solid_capstyle(s)

Set the cap style for solid linestyles.

s : {‘butt’, ‘round’, ‘projecting’}

set_solid_joinstyle(s)

Set the join style for solid linestyles.

s : {‘miter’, ‘round’, ‘bevel’}

set_transform(t)

set the Transformation instance used by this artist

t : matplotlib.transforms.Transform

set_url(url)

Sets the url for the artist.

url : str

set_visible(b)

Set the artist’s visibility.

b : bool

set_xdata(x)

Set the data array for x.

x : 1D array

set_ydata(y)

Set the data array for y.

y : 1D array

set_zorder(level)

Set the zorder for the artist. Artists with lower zorder values are drawn first.

level : float

property stale

If the artist is ‘stale’ and needs to be re-drawn for the output to match the internal state of the artist.

property sticky_edges

x and y sticky edge lists for autoscaling.

When performing autoscaling, if a data limit coincides with a value in the corresponding sticky_edges list, then no margin will be added–the view limit “sticks” to the edge. A typical usecase is histograms, where one usually expects no margin on the bottom edge (0) of the histogram.

This attribute cannot be assigned to; however, the x and y lists can be modified in place as needed.

>>> artist.sticky_edges.x[:] = (xmin, xmax)
>>> artist.sticky_edges.y[:] = (ymin, ymax)
update(props)

Update this artist’s properties from the dictionary prop.

update_from(other)

copy properties from other to self

class holoviews.plotting.mpl.annotation.AnnotationPlot(annotation, **params)[source]

Bases: holoviews.plotting.mpl.element.ElementPlot

AnnotationPlot handles the display of all annotation elements.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

show_legend = param.Boolean(bounds=(0, 1), default=False)

Whether to show legend for the plot.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, annotation, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.annotation.ArrowPlot(annotation, **params)[source]

Bases: holoviews.plotting.mpl.annotation.AnnotationPlot

Draw an arrow using the information supplied to the Arrow annotation

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.annotation.AnnotationPlot: show_legend

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, annotation, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.annotation.HLinePlot(annotation, **params)[source]

Bases: holoviews.plotting.mpl.annotation.AnnotationPlot

Draw a horizontal line on the axis

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.annotation.AnnotationPlot: show_legend

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

draw_annotation(axis, position, opts)[source]

Draw a horizontal line on the axis

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, annotation, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.annotation.HSpanPlot(annotation, **params)[source]

Bases: holoviews.plotting.mpl.annotation.AnnotationPlot

Draw a horizontal span on the axis

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.annotation.AnnotationPlot: show_legend

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

draw_annotation(axis, positions, opts)[source]

Draw a horizontal span on the axis

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, annotation, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.annotation.LabelsPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Index of the dimension from which the color will the drawn

xoffset = param.Number(inclusive_bounds=(True, True))

Amount of offset to apply to labels along x-axis.

yoffset = param.Number(inclusive_bounds=(True, True))

Amount of offset to apply to labels along x-axis.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()[source]

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.annotation.SlopePlot(annotation, **params)[source]

Bases: holoviews.plotting.mpl.annotation.AnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.annotation.AnnotationPlot: show_legend

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

draw_annotation(axis, position, opts)[source]

Draw a horizontal line on the axis

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, annotation, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.annotation.SplinePlot(annotation, **params)[source]

Bases: holoviews.plotting.mpl.annotation.AnnotationPlot

Draw the supplied Spline annotation (see Spline docstring)

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.annotation.AnnotationPlot: show_legend

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, annotation, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.annotation.TextPlot(annotation, **params)[source]

Bases: holoviews.plotting.mpl.annotation.AnnotationPlot

Draw the Text annotation object

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.annotation.AnnotationPlot: show_legend

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, annotation, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.annotation.VLinePlot(annotation, **params)[source]

Bases: holoviews.plotting.mpl.annotation.AnnotationPlot

Draw a vertical line on the axis

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.annotation.AnnotationPlot: show_legend

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, annotation, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.annotation.VSpanPlot(annotation, **params)[source]

Bases: holoviews.plotting.mpl.annotation.AnnotationPlot

Draw a vertical span on the axis

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.annotation.AnnotationPlot: show_legend

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

draw_annotation(axis, positions, opts)[source]

Draw a vertical span on the axis

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, annotation, ranges, style)

Update the elements of the plot.


chart Module

Inheritance diagram of holoviews.plotting.mpl.chart
class holoviews.plotting.mpl.chart.AreaPlot(element, **params)[source]

Bases: holoviews.plotting.mixins.AreaMixin, holoviews.plotting.mpl.chart.ChartPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

padding = param.ClassSelector(class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=(0, 0.1))

Fraction by which to increase auto-ranged extents to make datapoints more visible around borders. To compute padding, the axis whose screen size is largest is chosen, and the range of that axis is increased by the specified fraction along each axis. Other axes are then padded ensuring that the amount of screen space devoted to padding is equal for all axes. If specified as a tuple, the int or float values in the tuple will be used for padding in each axis, in order (x,y or x,y,z). For example, for padding=0.2 on a 800x800-pixel plot, an x-axis with the range [0,10] will be padded by 20% to be [-1,11], while a y-axis with a range [0,1000] will be padded to be [-100,1100], which should make the padding be approximately the same number of pixels. But if the same plot is changed to have a height of only 200, the y-range will then be [-400,1400] so that the y-axis padding will still match that of the x-axis. It is also possible to declare non-equal padding value for the lower and upper bound of an axis by supplying nested tuples, e.g. padding=(0.1, (0, 0.1)) will pad the x-axis lower and upper bound as well as the y-axis upper bound by a fraction of 0.1 while the y-axis lower bound is not padded at all.

show_legend = param.Boolean(bounds=(0, 1), default=False)

Whether to show legend for the plot.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_data, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.chart.BarPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mixins.BarsMixin, holoviews.plotting.mpl.element.ColorbarPlot, holoviews.plotting.mpl.element.LegendPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.LegendPlot: legend_cols, legend_position, legend_opts

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

show_legend = param.Boolean(bounds=(0, 1), default=True)

Whether to show legend for the plot.

bar_padding = param.Number(default=0.2, inclusive_bounds=(True, True))

Defines the padding between groups.

multi_level = param.Boolean(bounds=(0, 1), default=True)

Whether the Bars should be grouped into a second categorical axis level.

stacked = param.Boolean(bounds=(0, 1), default=False)

Whether the bars should be stacked or grouped.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

Make adjustments to plot extents by computing stacked bar heights, adjusting the bar baseline and forcing the x-axis to be categorical.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.chart.ChartPlot(element, **params)[source]

Bases: holoviews.plotting.mpl.element.ElementPlot

Baseclass to plot Chart elements.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.chart.CurvePlot(element, **params)[source]

Bases: holoviews.plotting.mpl.chart.ChartPlot

CurvePlot can plot Curve and ViewMaps of Curve, which can be displayed as a single frame or animation. Axes, titles and legends are automatically generated from dim_info.

If the dimension is set to cyclic in the dim_info it will rotate the curve so that minimum y values are at the minimum x value to make the plots easier to interpret.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

padding = param.ClassSelector(class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=(0, 0.1))

Fraction by which to increase auto-ranged extents to make datapoints more visible around borders. To compute padding, the axis whose screen size is largest is chosen, and the range of that axis is increased by the specified fraction along each axis. Other axes are then padded ensuring that the amount of screen space devoted to padding is equal for all axes. If specified as a tuple, the int or float values in the tuple will be used for padding in each axis, in order (x,y or x,y,z). For example, for padding=0.2 on a 800x800-pixel plot, an x-axis with the range [0,10] will be padded by 20% to be [-1,11], while a y-axis with a range [0,1000] will be padded to be [-100,1100], which should make the padding be approximately the same number of pixels. But if the same plot is changed to have a height of only 200, the y-range will then be [-400,1400] so that the y-axis padding will still match that of the x-axis. It is also possible to declare non-equal padding value for the lower and upper bound of an axis by supplying nested tuples, e.g. padding=(0.1, (0, 0.1)) will pad the x-axis lower and upper bound as well as the y-axis upper bound by a fraction of 0.1 while the y-axis lower bound is not padded at all.

show_legend = param.Boolean(bounds=(0, 1), default=True)

Whether to show legend for the plot.

show_grid = param.Boolean(bounds=(0, 1), default=False)

Enable axis grid.

autotick = param.Boolean(bounds=(0, 1), default=False)

Whether to let matplotlib automatically compute tick marks or to allow the user to control tick marks.

interpolation = param.ObjectSelector(default=’linear’, objects=[‘linear’, ‘steps-mid’, ‘steps-pre’, ‘steps-post’])

Defines how the samples of the Curve are interpolated, default is ‘linear’, other options include ‘steps-mid’, ‘steps-pre’ and ‘steps-post’.

relative_labels = param.Boolean(bounds=(0, 1), default=False)

If plotted quantity is cyclic and center_cyclic is enabled, will compute tick labels relative to the center.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.chart.ErrorPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

ErrorPlot plots the ErrorBar Element type and supporting both horizontal and vertical error bars via the ‘horizontal’ plot option.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_data, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.chart.HistogramPlot(histograms, **params)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

HistogramPlot can plot DataHistograms and ViewMaps of DataHistograms, which can be displayed as a single frame or animation.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')[source]

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.chart.PointPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.chart.ChartPlot, holoviews.plotting.mpl.element.ColorbarPlot

Note that the ‘cmap’, ‘vmin’ and ‘vmax’ style arguments control how point magnitudes are rendered to different colors.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

show_grid = param.Boolean(bounds=(0, 1), default=False)

Whether to draw grid lines at the tick positions.

color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Deprecated in favor of color style mapping, e.g. color=dim(‘color’)

size_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Deprecated in favor of size style mapping, e.g. size=dim(‘size’)

scaling_method = param.ObjectSelector(default=’area’, objects=[‘width’, ‘area’])

Deprecated in favor of size style mapping, e.g. size=dim(‘size’)**2.

scaling_factor = param.Number(bounds=(0, None), default=1, inclusive_bounds=(True, True))

Scaling factor which is applied to either the width or area of each point, depending on the value of scaling_method.

size_fn = param.Callable(default=<ufunc ‘absolute’>)

Function applied to size values before applying scaling, to remove values lower than zero.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

size_fn = <ufunc 'absolute'>
property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.chart.SideAreaPlot(element, **params)[source]

Bases: holoviews.plotting.mpl.plot.AdjoinedPlot, holoviews.plotting.mpl.chart.AreaPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.chart.AreaPlot: padding, show_legend

holoviews.plotting.mpl.plot.AdjoinedPlot: show_title, aspect, subplot_size, show_xlabel

bgcolor = param.Parameter(default=(1, 1, 1, 0))

Make plot background invisible.

xaxis = param.ObjectSelector(default=’bare’, objects=[‘top’, ‘bottom’, ‘bare’, ‘top-bare’, ‘bottom-bare’, None])

Whether and where to display the xaxis, bare options allow suppressing all axis labels including ticks and xlabel. Valid options are ‘top’, ‘bottom’, ‘bare’, ‘top-bare’ and ‘bottom-bare’.

yaxis = param.ObjectSelector(default=’bare’, objects=[‘left’, ‘right’, ‘bare’, ‘left-bare’, ‘right-bare’, None])

Whether and where to display the yaxis, bare options allow suppressing all axis labels including ticks and ylabel. Valid options are ‘left’, ‘right’, ‘bare’ ‘left-bare’ and ‘right-bare’.

border_size = param.Number(default=0, inclusive_bounds=(True, True))

The size of the border expressed as a fraction of the main plot.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_data, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.chart.SideHistogramPlot(histograms, **params)[source]

Bases: holoviews.plotting.mpl.plot.AdjoinedPlot, holoviews.plotting.mpl.chart.HistogramPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.plot.AdjoinedPlot: show_title, aspect, border_size, subplot_size, show_xlabel

bgcolor = param.Parameter(default=(1, 1, 1, 0))

Make plot background invisible.

show_grid = param.Boolean(bounds=(0, 1), default=False)

Whether to overlay a grid on the axis.

offset = param.Number(bounds=(0, 1), default=0.2, inclusive_bounds=(True, True))

Histogram value offset for a colorbar.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.chart.SideSpikesPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.plot.AdjoinedPlot, holoviews.plotting.mpl.chart.SpikesPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.path.PathPlot: show_legend

holoviews.plotting.mpl.chart.SpikesPlot: padding, color_index, position

holoviews.plotting.mpl.plot.AdjoinedPlot: show_title, aspect, show_xlabel

show_frame = param.Boolean(bounds=(0, 1), default=True)

Whether or not to show a complete frame around the plot.

bgcolor = param.Parameter(default=(1, 1, 1, 0))

Make plot background invisible.

xaxis = param.ObjectSelector(default=’bare’, objects=[‘top’, ‘bottom’, ‘bare’, ‘top-bare’, ‘bottom-bare’, None])

Whether and where to display the xaxis, bare options allow suppressing all axis labels including ticks and xlabel. Valid options are ‘top’, ‘bottom’, ‘bare’, ‘top-bare’ and ‘bottom-bare’.

yaxis = param.ObjectSelector(default=’bare’, objects=[‘left’, ‘right’, ‘bare’, ‘left-bare’, ‘right-bare’, None])

Whether and where to display the yaxis, bare options allow suppressing all axis labels including ticks and ylabel. Valid options are ‘left’, ‘right’, ‘bare’ ‘left-bare’ and ‘right-bare’.

spike_length = param.Number(default=1, inclusive_bounds=(True, True))

The length of each spike if Spikes object is one dimensional.

border_size = param.Number(default=0, inclusive_bounds=(True, True))

The size of the border expressed as a fraction of the main plot.

subplot_size = param.Number(default=0.1, inclusive_bounds=(True, True))

The size subplots as expressed as a fraction of the main plot.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.chart.SpikesPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mixins.SpikesMixin, holoviews.plotting.mpl.path.PathPlot, holoviews.plotting.mpl.element.ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.path.PathPlot: show_legend

padding = param.ClassSelector(class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=(0, 0.1))

Fraction by which to increase auto-ranged extents to make datapoints more visible around borders. To compute padding, the axis whose screen size is largest is chosen, and the range of that axis is increased by the specified fraction along each axis. Other axes are then padded ensuring that the amount of screen space devoted to padding is equal for all axes. If specified as a tuple, the int or float values in the tuple will be used for padding in each axis, in order (x,y or x,y,z). For example, for padding=0.2 on a 800x800-pixel plot, an x-axis with the range [0,10] will be padded by 20% to be [-1,11], while a y-axis with a range [0,1000] will be padded to be [-100,1100], which should make the padding be approximately the same number of pixels. But if the same plot is changed to have a height of only 200, the y-range will then be [-400,1400] so that the y-axis padding will still match that of the x-axis. It is also possible to declare non-equal padding value for the lower and upper bound of an axis by supplying nested tuples, e.g. padding=(0.1, (0, 0.1)) will pad the x-axis lower and upper bound as well as the y-axis upper bound by a fraction of 0.1 while the y-axis lower bound is not padded at all.

aspect = param.Parameter(default=’square’)

The aspect ratio mode of the plot. Allows setting an explicit aspect ratio as width/height as well as ‘square’ and ‘equal’ options.

color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Index of the dimension from which the color will the drawn

spike_length = param.Number(default=0.1, inclusive_bounds=(True, True))

The length of each spike if Spikes object is one dimensional.

position = param.Number(default=0.0, inclusive_bounds=(True, True))

The position of the lower end of each spike.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.chart.SpreadPlot(element, **params)[source]

Bases: holoviews.plotting.mpl.chart.AreaPlot

SpreadPlot plots the Spread Element type.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

padding = param.ClassSelector(class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=(0, 0.1))

Fraction by which to increase auto-ranged extents to make datapoints more visible around borders. To compute padding, the axis whose screen size is largest is chosen, and the range of that axis is increased by the specified fraction along each axis. Other axes are then padded ensuring that the amount of screen space devoted to padding is equal for all axes. If specified as a tuple, the int or float values in the tuple will be used for padding in each axis, in order (x,y or x,y,z). For example, for padding=0.2 on a 800x800-pixel plot, an x-axis with the range [0,10] will be padded by 20% to be [-1,11], while a y-axis with a range [0,1000] will be padded to be [-100,1100], which should make the padding be approximately the same number of pixels. But if the same plot is changed to have a height of only 200, the y-range will then be [-400,1400] so that the y-axis padding will still match that of the x-axis. It is also possible to declare non-equal padding value for the lower and upper bound of an axis by supplying nested tuples, e.g. padding=(0.1, (0, 0.1)) will pad the x-axis lower and upper bound as well as the y-axis upper bound by a fraction of 0.1 while the y-axis lower bound is not padded at all.

show_legend = param.Boolean(bounds=(0, 1), default=False)

Whether to show legend for the plot.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')[source]

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_data, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.chart.VectorFieldPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

Renders vector fields in sheet coordinates. The vectors are expressed in polar coordinates and may be displayed according to angle alone (with some common, arbitrary arrow length) or may be true polar vectors.

The color or magnitude can be mapped onto any dimension using the color_index and size_index.

The length of the arrows is controlled by the ‘scale’ style option. The scaling of the arrows may also be controlled via the normalize_lengths and rescale_lengths plot option, which will normalize the lengths to a maximum of 1 and scale them according to the minimum distance respectively.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

padding = param.ClassSelector(class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=0.05)

Fraction by which to increase auto-ranged extents to make datapoints more visible around borders. To compute padding, the axis whose screen size is largest is chosen, and the range of that axis is increased by the specified fraction along each axis. Other axes are then padded ensuring that the amount of screen space devoted to padding is equal for all axes. If specified as a tuple, the int or float values in the tuple will be used for padding in each axis, in order (x,y or x,y,z). For example, for padding=0.2 on a 800x800-pixel plot, an x-axis with the range [0,10] will be padded by 20% to be [-1,11], while a y-axis with a range [0,1000] will be padded to be [-100,1100], which should make the padding be approximately the same number of pixels. But if the same plot is changed to have a height of only 200, the y-range will then be [-400,1400] so that the y-axis padding will still match that of the x-axis. It is also possible to declare non-equal padding value for the lower and upper bound of an axis by supplying nested tuples, e.g. padding=(0.1, (0, 0.1)) will pad the x-axis lower and upper bound as well as the y-axis upper bound by a fraction of 0.1 while the y-axis lower bound is not padded at all.

arrow_heads = param.Boolean(bounds=(0, 1), default=True)

Whether or not to draw arrow heads. If arrowheads are enabled, they may be customized with the ‘headlength’ and ‘headaxislength’ style options.

magnitude = param.ClassSelector(class_=(<class ‘str’>, <class ‘holoviews.util.transform.dim’>))

Dimension or dimension value transform that declares the magnitude of each vector. Magnitude is expected to be scaled between 0-1, by default the magnitudes are rescaled relative to the minimum distance between vectors, this can be disabled with the rescale_lengths option.

rescale_lengths = param.Boolean(bounds=(0, 1), default=True)

Whether the lengths will be rescaled to take into account the smallest non-zero distance between two vectors.

color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Deprecated in favor of dimension value transform on color option, e.g. color=dim(‘Magnitude’).

size_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Deprecated in favor of the magnitude option, e.g. magnitude=dim(‘Magnitude’).

normalize_lengths = param.Boolean(bounds=(0, 1), default=True)

Deprecated in favor of rescaling length using dimension value transforms using the magnitude option, e.g. dim(‘Magnitude’).norm().

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.


chart3d Module

Inheritance diagram of holoviews.plotting.mpl.chart3d
class holoviews.plotting.mpl.chart3d.Path3DPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.chart3d.Plot3D, holoviews.plotting.mpl.path.PathPlot

Allows plotting paths on a 3D axis.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, logz, xformatter, yformatter, zformatter, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.path.PathPlot: show_legend, aspect, color_index

holoviews.plotting.mpl.chart3d.Plot3D: projection, bgcolor, show_grid, xaxis, yaxis, labelled, zaxis, azimuth, elevation, distance, disable_axes

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.chart3d.Plot3D(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

Plot3D provides a common baseclass for mplot3d based plots.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, logz, xformatter, yformatter, zformatter, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

projection = param.ObjectSelector(default=’3d’, objects=[‘3d’])

The projection of the matplotlib axis.

bgcolor = param.String(default=’white’)

Background color of the axis.

show_grid = param.Boolean(bounds=(0, 1), default=True)

Whether to draw a grid in the figure.

xaxis = param.ObjectSelector(default=’fixed’, objects=[‘fixed’, None])

Whether and where to display the xaxis.

yaxis = param.ObjectSelector(default=’fixed’, objects=[‘fixed’, None])

Whether and where to display the yaxis.

labelled = param.List(bounds=(0, None), default=[‘x’, ‘y’, ‘z’])

Whether to plot the ‘x’, ‘y’ and ‘z’ labels.

zaxis = param.ObjectSelector(default=’fixed’, objects=[‘fixed’, None])

Whether and where to display the yaxis.

azimuth = param.Integer(bounds=(-180, 180), default=-60, inclusive_bounds=(True, True))

Azimuth angle in the x,y plane.

elevation = param.Integer(bounds=(0, 180), default=30, inclusive_bounds=(True, True))

Elevation angle in the z-axis.

distance = param.Integer(bounds=(7, 15), default=10, inclusive_bounds=(True, True))

Distance from the plotted object.

disable_axes = param.Boolean(bounds=(0, 1), default=False)

Disable all axes.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.chart3d.Scatter3DPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.chart3d.Plot3D, holoviews.plotting.mpl.chart.PointPlot

Subclass of PointPlot allowing plotting of Points on a 3D axis, also allows mapping color and size onto a particular Dimension of the data.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, logz, xformatter, yformatter, zformatter, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.chart.PointPlot: scaling_method, scaling_factor, size_fn

holoviews.plotting.mpl.chart3d.Plot3D: projection, bgcolor, show_grid, xaxis, yaxis, labelled, zaxis, azimuth, elevation, distance, disable_axes

color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Index of the dimension from which the color will the drawn

size_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Index of the dimension from which the sizes will the drawn.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

size_fn = <ufunc 'absolute'>
property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.chart3d.SurfacePlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.chart3d.Plot3D

Plots surfaces wireframes and contours in 3D space. Provides options to switch the display type via the plot_type parameter has support for a number of styling options including strides and colors.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, logz, xformatter, yformatter, zformatter, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.chart3d.Plot3D: projection, bgcolor, show_grid, xaxis, yaxis, labelled, zaxis, azimuth, elevation, distance, disable_axes

colorbar = param.Boolean(bounds=(0, 1), default=False)

Whether to add a colorbar to the plot.

plot_type = param.ObjectSelector(default=’surface’, objects=[‘surface’, ‘wireframe’, ‘contour’])

Specifies the type of visualization for the Surface object. Valid values are ‘surface’, ‘wireframe’ and ‘contour’.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_data, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.chart3d.TriSurfacePlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.chart3d.Plot3D

Plots a trisurface given a TriSurface element, containing X, Y and Z coordinates.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, logz, xformatter, yformatter, zformatter, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.chart3d.Plot3D: projection, bgcolor, show_grid, xaxis, yaxis, labelled, zaxis, azimuth, elevation, distance, disable_axes

colorbar = param.Boolean(bounds=(0, 1), default=False)

Whether to add a colorbar to the plot.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.


element Module

Inheritance diagram of holoviews.plotting.mpl.element
class holoviews.plotting.mpl.element.ColorbarPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ElementPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

clabel = param.String()

An explicit override of the color bar label, if set takes precedence over the title key in colorbar_opts.

clim = param.NumericTuple(default=(nan, nan), 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.

cformatter = param.ClassSelector(class_=(<class ‘str’>, <class ‘matplotlib.ticker.Formatter’>, <class ‘function’>))

Formatter for ticks along the colorbar axis.

colorbar = param.Boolean(bounds=(0, 1), default=False)

Whether to draw a colorbar.

colorbar_opts = param.Dict(class_=<class ‘dict’>, default={})

Allows setting specific styling options for the colorbar.

color_levels = param.ClassSelector(class_=(<class ‘int’>, <class ‘list’>))

Number of discrete colors to use when colormapping or a set of color intervals defining the range of values to map each color to.

clipping_colors = param.Dict(class_=<class ‘dict’>, default={})

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 = param.Number(default=0.01, inclusive_bounds=(True, True))

Padding between colorbar and other plots.

cbar_ticks = param.Parameter()

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 = param.Number(default=0.05, inclusive_bounds=(True, True))

Width of the colorbar as a fraction of the main plot

cbar_extend = param.ObjectSelector(objects=[‘neither’, ‘both’, ‘min’, ‘max’])

If not ‘neither’, make pointed end(s) for out-of- range values.

symmetric = param.Boolean(bounds=(0, 1), default=False)

Whether to make the colormap symmetric around zero.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.element.ElementPlot(element, **params)[source]

Bases: holoviews.plotting.plot.GenericElementPlot, holoviews.plotting.mpl.plot.MPLPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

apply_ticks = param.Boolean(bounds=(0, 1), default=True)

Whether to apply custom ticks.

aspect = param.Parameter(default=’square’)

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 = param.Number(inclusive_bounds=(True, True))

Defines the aspect of the axis scaling, i.e. the ratio of y-unit to x-unit.

invert_zaxis = param.Boolean(bounds=(0, 1), default=False)

Whether to invert the plot z-axis.

labelled = param.List(bounds=(0, None), default=[‘x’, ‘y’])

Whether to plot the ‘x’ and ‘y’ labels.

logz = param.Boolean(bounds=(0, 1), default=False)

Whether to apply log scaling to the y-axis of the Chart.

xformatter = param.ClassSelector(class_=(<class ‘str’>, <class ‘matplotlib.ticker.Formatter’>, <class ‘function’>))

Formatter for ticks along the x-axis.

yformatter = param.ClassSelector(class_=(<class ‘str’>, <class ‘matplotlib.ticker.Formatter’>, <class ‘function’>))

Formatter for ticks along the y-axis.

zformatter = param.ClassSelector(class_=(<class ‘str’>, <class ‘matplotlib.ticker.Formatter’>, <class ‘function’>))

Formatter for ticks along the z-axis.

zaxis = param.Boolean(bounds=(0, 1), default=True)

Whether to display the z-axis.

zlabel = param.String()

An explicit override of the z-axis label, if set takes precedence over the dimension label.

zrotation = param.Integer(bounds=(0, 360), default=0, inclusive_bounds=(True, True))

Rotation angle of the zticks.

zticks = param.Parameter()

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.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)[source]

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()[source]

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.element.LegendPlot(element, **params)[source]

Bases: holoviews.plotting.mpl.element.ElementPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

show_legend = param.Boolean(bounds=(0, 1), default=True)

Whether to show legend for the plot.

legend_cols = param.Integer(inclusive_bounds=(True, True))

Number of legend columns in the legend.

legend_position = param.ObjectSelector(default=’inner’, 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 = param.Dict(class_=<class ‘dict’>, default={})

Allows setting specific styling options for the colorbar.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.element.OverlayPlot(overlay, ranges=None, **params)[source]

Bases: holoviews.plotting.mpl.element.LegendPlot, holoviews.plotting.plot.GenericOverlayPlot

OverlayPlot supports compositors processing of Overlays across maps.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.plot.GenericOverlayPlot: batched, legend_limit, style_grouping

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.LegendPlot: show_legend, legend_cols, legend_position, legend_opts

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(overlay, ranges, range_type='combined')

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.


geometry Module

Inheritance diagram of holoviews.plotting.mpl.geometry
class holoviews.plotting.mpl.geometry.RectanglesPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mixins.GeomMixin, holoviews.plotting.mpl.element.ColorbarPlot

Rectanlges are polygons in 2D space where the key dimensions represent the bottom-left and top-right corner of the rectangle.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

Use first two key dimensions to set names, and all four to set the data range.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.geometry.SegmentPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mixins.GeomMixin, holoviews.plotting.mpl.element.ColorbarPlot

Segments are lines in 2D space where each two key dimensions specify a (x, y) node of the line.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

Use first two key dimensions to set names, and all four to set the data range.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.


graphs Module

Inheritance diagram of holoviews.plotting.mpl.graphs
class holoviews.plotting.mpl.graphs.ChordPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mixins.ChordMixin, holoviews.plotting.mpl.graphs.GraphPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.graphs.GraphPlot: arrowhead_length, directed, color_index, edge_color_index

labels = param.ClassSelector(class_=(<class ‘str’>, <class ‘holoviews.util.transform.dim’>))

The dimension or dimension value transform used to draw labels from.

label_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Index of the dimension from which the node labels will be drawn

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

A Chord plot is always drawn on a unit circle.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.graphs.GraphPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

arrowhead_length = param.Number(default=0.025, inclusive_bounds=(True, True))

If directed option is enabled this determines the length of the arrows as fraction of the overall extent of the graph.

directed = param.Boolean(bounds=(0, 1), default=False)

Whether to draw arrows on the graph edges to indicate the directionality of each edge.

color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Deprecated in favor of color style mapping, e.g. node_color=dim(‘color’)

edge_color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Deprecated in favor of color style mapping, e.g. edge_color=dim(‘color’)

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')[source]

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.graphs.TriMeshPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.graphs.GraphPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.graphs.GraphPlot: arrowhead_length, directed, color_index, edge_color_index

filled = param.Boolean(bounds=(0, 1), default=False)

Whether the triangles should be drawn as filled.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.


heatmap Module

Inheritance diagram of holoviews.plotting.mpl.heatmap
class holoviews.plotting.mpl.heatmap.HeatMapPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mixins.HeatMapMixin, holoviews.plotting.mpl.raster.QuadMeshPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.raster.QuadMeshPlot: show_legend

padding = param.ClassSelector(class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=0)

Fraction by which to increase auto-ranged extents to make datapoints more visible around borders. To compute padding, the axis whose screen size is largest is chosen, and the range of that axis is increased by the specified fraction along each axis. Other axes are then padded ensuring that the amount of screen space devoted to padding is equal for all axes. If specified as a tuple, the int or float values in the tuple will be used for padding in each axis, in order (x,y or x,y,z). For example, for padding=0.2 on a 800x800-pixel plot, an x-axis with the range [0,10] will be padded by 20% to be [-1,11], while a y-axis with a range [0,1000] will be padded to be [-100,1100], which should make the padding be approximately the same number of pixels. But if the same plot is changed to have a height of only 200, the y-range will then be [-400,1400] so that the y-axis padding will still match that of the x-axis. It is also possible to declare non-equal padding value for the lower and upper bound of an axis by supplying nested tuples, e.g. padding=(0.1, (0, 0.1)) will pad the x-axis lower and upper bound as well as the y-axis upper bound by a fraction of 0.1 while the y-axis lower bound is not padded at all.

xticks = param.Parameter(default=20)

Ticks along x-axis/segments specified as an integer, explicit list of ticks or function. If None, no ticks are shown.

yticks = param.Parameter(default=20)

Ticks along y-axis/annulars specified as an integer, explicit list of ticks or function. If None, no ticks are shown.

clipping_colors = param.Dict(class_=<class ‘dict’>, default={‘NaN’: ‘white’})

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.

radial = param.Boolean(bounds=(0, 1), default=False)

Whether the HeatMap should be radial

show_values = param.Boolean(bounds=(0, 1), default=False)

Whether to annotate each pixel with its value.

xmarks = param.Parameter()

Add separation lines to the heatmap for better readability. By default, does not show any separation lines. If parameter is of type integer, draws the given amount of separations lines spread across heatmap. If parameter is of type list containing integers, show separation lines at given indices. If parameter is of type tuple, draw separation lines at given categorical values. If parameter is of type function, draw separation lines where function returns True for passed heatmap category.

ymarks = param.Parameter()

Add separation lines to the heatmap for better readability. By default, does not show any separation lines. If parameter is of type integer, draws the given amount of separations lines spread across heatmap. If parameter is of type list containing integers, show separation lines at given indices. If parameter is of type tuple, draw separation lines at given categorical values. If parameter is of type function, draw separation lines where function returns True for passed heatmap category.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.heatmap.RadialHeatMapPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

projection = param.ObjectSelector(default=’polar’, objects=[‘polar’])

The projection of the plot axis, default of None is equivalent to 2D plot, ‘3d’ and ‘polar’ are also supported by matplotlib by default. May also supply a custom projection that is either a matplotlib projection type or implements the _as_mpl_axes method.

xticks = param.Parameter(default=4)

Ticks along x-axis/segments specified as an integer, explicit list of ticks or function. If None, no ticks are shown.

yticks = param.Parameter(default=4)

Ticks along y-axis/annulars specified as an integer, explicit list of ticks or function. If None, no ticks are shown.

start_angle = param.Number(default=1.5707963267948966, inclusive_bounds=(True, True))

Define starting angle of the first annulars. By default, beings at 12 o clock.

max_radius = param.Number(default=0.5, inclusive_bounds=(True, True))

Define the maximum radius which is used for the x and y range extents.

radius_inner = param.Number(bounds=(0, 0.5), default=0.1, inclusive_bounds=(True, True))

Define the radius fraction of inner, empty space.

radius_outer = param.Number(bounds=(0, 1), default=0.05, inclusive_bounds=(True, True))

Define the radius fraction of outer space including the labels.

radial = param.Boolean(bounds=(0, 1), default=True)

Whether the HeatMap should be radial

show_values = param.Boolean(bounds=(0, 1), default=False)

Whether to annotate each pixel with its value.

xmarks = param.Parameter()

Add separation lines between segments for better readability. By default, does not show any separation lines. If parameter is of type integer, draws the given amount of separations lines spread across radial heatmap. If parameter is of type list containing integers, show separation lines at given indices. If parameter is of type tuple, draw separation lines at given segment values. If parameter is of type function, draw separation lines where function returns True for passed segment value.

ymarks = param.Parameter()

Add separation lines between annulars for better readability. By default, does not show any separation lines. If parameter is of type integer, draws the given amount of separations lines spread across radial heatmap. If parameter is of type list containing integers, show separation lines at given indices. If parameter is of type tuple, draw separation lines at given annular values. If parameter is of type function, draw separation lines where function returns True for passed annular value.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(view, ranges, range_type='combined')[source]

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.


hex_tiles Module

Inheritance diagram of holoviews.plotting.mpl.hex_tiles
class holoviews.plotting.mpl.hex_tiles.HexTilesPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

aggregator = param.Callable()

Aggregation function used to compute bin values. Any NumPy reduction is allowed, defaulting to np.size to count the number of values in each bin.

gridsize = param.ClassSelector(class_=(<class ‘int’>, <class ‘tuple’>), default=50)

Number of hexagonal bins along x- and y-axes. Defaults to uniform sampling along both axes when setting and integer but independent bin sampling can be specified a tuple of integers corresponding to the number of bins along each axis.

max_scale = param.Number(bounds=(0, None), default=0.9, inclusive_bounds=(True, True))

When size_index is enabled this defines the maximum size of each bin relative to uniform tile size, i.e. for a value of 1, the largest bin will match the size of bins when scaling is disabled. Setting value larger than 1 will result in overlapping bins.

min_count = param.Number(inclusive_bounds=(True, True))

The display threshold before a bin is shown, by default bins with a count of less than 1 are hidden.

aggregator(axis=None)

Return the number of elements along a given axis.

aarray_like

Input data.

axisint, optional

Axis along which the elements are counted. By default, give the total number of elements.

element_countint

Number of elements along the specified axis.

shape : dimensions of array ndarray.shape : dimensions of array ndarray.size : number of elements in array

>>> a = np.array([[1,2,3],[4,5,6]])
>>> np.size(a)
6
>>> np.size(a,1)
3
>>> np.size(a,0)
2
anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.


path Module

Inheritance diagram of holoviews.plotting.mpl.path
class holoviews.plotting.mpl.path.ContourPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.path.PathPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.path.PathPlot: show_legend, aspect

color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>), default=0)

Index of the dimension from which the color will the drawn

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.path.PathPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

show_legend = param.Boolean(bounds=(0, 1), default=False)

Whether to show legend for the plot.

aspect = param.Parameter(default=’square’)

PathPlots axes usually define single space so aspect of Paths follows aspect in data coordinates by default.

color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>))

Index of the dimension from which the color will the drawn

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.path.PolygonPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.path.ContourPlot

PolygonPlot draws the polygon paths in the supplied Polygons object. If the Polygon has an associated value the color of Polygons will be drawn from the supplied cmap, otherwise the supplied facecolor will apply. Facecolor also determines the color for non-finite values.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.path.PathPlot: aspect

holoviews.plotting.mpl.path.ContourPlot: color_index

show_legend = param.Boolean(bounds=(0, 1), default=False)

Whether to show legend for the plot.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.


plot Module

Inheritance diagram of holoviews.plotting.mpl.plot
class holoviews.plotting.mpl.plot.AdjoinedPlot(keys=None, dimensions=None, layout_dimensions=None, uniform=True, subplot=False, adjoined=None, layout_num=0, style=None, subplots=None, dynamic=False, **params)[source]

Bases: holoviews.plotting.plot.DimensionedPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, title, title_format, normalize, projection

show_title = param.Boolean(bounds=(0, 1), default=False)

Titles should be disabled on all SidePlots to avoid clutter.

aspect = param.Parameter(default=’auto’)

Aspect ratios on SideHistogramPlot should be determined by the AdjointLayoutPlot.

bgcolor = param.Parameter(default=(1, 1, 1, 0))

Make plot background invisible.

border_size = param.Number(default=0.25, inclusive_bounds=(True, True))

The size of the border expressed as a fraction of the main plot.

subplot_size = param.Number(default=0.25, inclusive_bounds=(True, True))

The size subplots as expressed as a fraction of the main plot.

show_xlabel = param.Boolean(bounds=(0, 1), default=False)

Whether to show the x-label of the plot. Disabled by default because plots are often too cramped to fit the title correctly.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

initialize_plot(ranges=None)

Initialize the matplotlib figure.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

class holoviews.plotting.mpl.plot.AdjointLayoutPlot(layout, layout_type, subaxes, subplots, **params)[source]

Bases: holoviews.plotting.mpl.plot.MPLPlot, holoviews.plotting.plot.GenericAdjointLayoutPlot

Initially, a AdjointLayoutPlot computes an appropriate layout based for the number of Views in the AdjointLayout object it has been given, but when embedded in a NdLayout, it can recompute the layout to match the number of rows and columns as part of a larger grid.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

adjust_positions(redraw=True)[source]

Make adjustments to the positions of subplots (if available) relative to the main plot axes as required.

This method is called by LayoutPlot after an initial pass used to position all the Layouts together. This method allows LayoutPlots to make final adjustments to the axis positions.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

class holoviews.plotting.mpl.plot.CompositePlot(layout, keys=None, dimensions=None, **params)[source]

Bases: holoviews.plotting.plot.GenericCompositePlot, holoviews.plotting.mpl.plot.MPLPlot

CompositePlot provides a baseclass for plots coordinate multiple subplots to form a Layout.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

shared_axes = param.Boolean(bounds=(0, 1), default=True)

Whether axes ranges should be shared across the layout, if disabled switches axiswise normalization option on globally.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

initialize_plot(ranges=None)

Initialize the matplotlib figure.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

class holoviews.plotting.mpl.plot.GridPlot(layout, axis=None, create_axes=True, ranges=None, layout_num=1, keys=None, **params)[source]

Bases: holoviews.plotting.mpl.plot.CompositePlot

Plot a group of elements in a grid layout based on a GridSpace element object.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.mpl.plot.CompositePlot: shared_axes

aspect = param.Parameter(default=’equal’)

Aspect ratios on GridPlot should be automatically determined.

padding = param.Number(default=0.1, inclusive_bounds=(True, True))

The amount of padding as a fraction of the total Grid size

shared_xaxis = param.Boolean(bounds=(0, 1), default=False)

If enabled the x-axes of the GridSpace will be drawn from the objects inside the Grid rather than the GridSpace dimensions.

shared_yaxis = param.Boolean(bounds=(0, 1), default=False)

If enabled the x-axes of the GridSpace will be drawn from the objects inside the Grid rather than the GridSpace dimensions.

show_legend = param.Boolean(bounds=(0, 1), default=False)

Legends add to much clutter in a grid and are disabled by default.

xaxis = param.ObjectSelector(default=’bottom’, objects=[‘bottom’, ‘top’, None])

Whether and where to display the xaxis, supported options are ‘bottom’, ‘top’ and None.

yaxis = param.ObjectSelector(default=’left’, objects=[‘left’, ‘right’, None])

Whether and where to display the yaxis, supported options are ‘left’, ‘right’ and None.

xrotation = param.Integer(bounds=(0, 360), default=0, inclusive_bounds=(True, True))

Rotation angle of the xticks.

yrotation = param.Integer(bounds=(0, 360), default=0, inclusive_bounds=(True, True))

Rotation angle of the yticks.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

class holoviews.plotting.mpl.plot.LayoutPlot(layout, keys=None, **params)[source]

Bases: holoviews.plotting.plot.GenericLayoutPlot, holoviews.plotting.mpl.plot.CompositePlot

A LayoutPlot accepts either a Layout or a NdLayout and displays the elements in a cartesian grid in scanline order.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.mpl.plot.CompositePlot: shared_axes

holoviews.plotting.plot.GenericLayoutPlot: transpose

fontsize = param.Parameter(default={‘title’: 16})

Specifies various font sizes of the displayed text. Finer control is available by supplying a dictionary where any unmentioned keys revert to the default sizes, e.g: {‘ticks’:20, ‘title’:15, ‘ylabel’:5, ‘xlabel’:5, ‘zlabel’:5, ‘legend’:8, ‘legend_title’:13} You can set the font size of ‘zlabel’, ‘ylabel’ and ‘xlabel’ together using the ‘labels’ key.

fig_bounds = param.NumericTuple(default=(0.05, 0.05, 0.95, 0.95), length=4)

The bounds of the figure as a 4-tuple of the form (left, bottom, right, top), defining the size of the border around the subplots.

absolute_scaling = param.ObjectSelector(default=False, objects=[])

If aspect_weight is enabled absolute_scaling determines whether axes are scaled relative to the widest plot or whether the aspect scales the axes in absolute terms.

aspect_weight = param.Number(default=0, inclusive_bounds=(True, True))

Weighting of the individual aspects when computing the Layout grid aspects and overall figure size.

tight = param.Boolean(bounds=(0, 1), default=False)

Tightly fit the axes in the layout within the fig_bounds and tight_padding.

tight_padding = param.Parameter(default=3)

Integer or tuple specifying the padding in inches in a tight layout.

hspace = param.Number(default=0.5, inclusive_bounds=(True, True))

Specifies the space between horizontally adjacent elements in the grid. Default value is set conservatively to avoid overlap of subplots.

vspace = param.Number(default=0.3, inclusive_bounds=(True, True))

Specifies the space between vertically adjacent elements in the grid. Default value is set conservatively to avoid overlap of subplots.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

grid_situate(current_idx, layout_type, subgrid_width)[source]

Situate the current AdjointLayoutPlot in a LayoutPlot. The LayoutPlot specifies a layout_type into which the AdjointLayoutPlot must be embedded. This enclosing layout is guaranteed to have enough cells to display all the views.

Based on this enforced layout format, a starting index supplied by LayoutPlot (indexing into a large gridspec arrangement) is updated to the appropriate embedded value. It will also return a list of gridspec indices associated with the all the required layout axes.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

class holoviews.plotting.mpl.plot.MPLPlot(fig=None, axis=None, **params)[source]

Bases: holoviews.plotting.plot.DimensionedPlot

An MPLPlot object draws a matplotlib figure object when called or indexed but can also return a matplotlib animation object as appropriate. MPLPlots take element objects such as Image, Contours or Points as inputs and plots them in the appropriate format using matplotlib. As HoloMaps are supported, all plots support animation via the anim() method.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

projection = param.Parameter()

The projection of the plot axis, default of None is equivalent to 2D plot, ‘3d’ and ‘polar’ are also supported by matplotlib by default. May also supply a custom projection that is either a matplotlib projection type or implements the _as_mpl_axes method.

fig_alpha = param.Number(bounds=(0, 1), default=1.0, inclusive_bounds=(True, True))

Alpha of the overall figure background.

fig_bounds = param.NumericTuple(default=(0.15, 0.15, 0.85, 0.85), length=4)

The bounds of the overall figure as a 4-tuple of the form (left, bottom, right, top), defining the size of the border around the subplots.

fig_inches = param.Parameter(default=4)

The overall matplotlib figure size in inches. May be set as an integer in which case it will be used to autocompute a size. Alternatively may be set with an explicit tuple or list, in which case it will be applied directly after being scaled by fig_size. If either the width or height is set to None, it will be computed automatically.

fig_latex = param.Boolean(bounds=(0, 1), default=False)

Whether to use LaTeX text in the overall figure.

fig_rcparams = param.Dict(class_=<class ‘dict’>, default={})

matplotlib rc parameters to apply to the overall figure.

fig_size = param.Number(bounds=(1, None), default=100.0, inclusive_bounds=(True, True))

Size relative to the supplied overall fig_inches in percent.

initial_hooks = param.HookList(bounds=(0, None), default=[])

Optional list of hooks called before plotting the data onto the axis (now marked for deprecation). The hook is passed the plot object and the displayed object; other plotting handles can be accessed via plot.handles.

sublabel_format = param.String()

Allows labeling the subaxes in each plot with various formatters including {Alpha}, {alpha}, {numeric} and {roman}.

sublabel_position = param.NumericTuple(default=(-0.35, 0.85), length=2)

Position relative to the plot for placing the optional subfigure label.

sublabel_size = param.Number(default=18, inclusive_bounds=(True, True))

Size of optional subfigure label.

show_frame = param.Boolean(bounds=(0, 1), default=False)

Whether or not to show a complete frame around the plot.

anim(start=0, stop=None, fps=30)[source]

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

initialize_plot(ranges=None)

Initialize the matplotlib figure.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)[source]

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

holoviews.plotting.mpl.plot.mpl_rc_context(f)[source]

Decorator for MPLPlot methods applying the matplotlib rc params in the plots fig_rcparams while when method is called.


raster Module

Inheritance diagram of holoviews.plotting.mpl.raster
class holoviews.plotting.mpl.raster.QuadMeshPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.element.ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

padding = param.ClassSelector(class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=0)

Fraction by which to increase auto-ranged extents to make datapoints more visible around borders. To compute padding, the axis whose screen size is largest is chosen, and the range of that axis is increased by the specified fraction along each axis. Other axes are then padded ensuring that the amount of screen space devoted to padding is equal for all axes. If specified as a tuple, the int or float values in the tuple will be used for padding in each axis, in order (x,y or x,y,z). For example, for padding=0.2 on a 800x800-pixel plot, an x-axis with the range [0,10] will be padded by 20% to be [-1,11], while a y-axis with a range [0,1000] will be padded to be [-100,1100], which should make the padding be approximately the same number of pixels. But if the same plot is changed to have a height of only 200, the y-range will then be [-400,1400] so that the y-axis padding will still match that of the x-axis. It is also possible to declare non-equal padding value for the lower and upper bound of an axis by supplying nested tuples, e.g. padding=(0.1, (0, 0.1)) will pad the x-axis lower and upper bound as well as the y-axis upper bound by a fraction of 0.1 while the y-axis lower bound is not padded at all.

show_legend = param.Boolean(bounds=(0, 1), default=False)

Whether to show legend for the plot.

clipping_colors = param.Dict(class_=<class ‘dict’>, default={‘NaN’: ‘transparent’})

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.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.raster.RGBPlot(element, **params)[source]

Bases: holoviews.plotting.mpl.raster.RasterBasePlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.raster.RasterBasePlot: padding, show_legend, aspect, situate_axes

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.

class holoviews.plotting.mpl.raster.RasterBasePlot(element, **params)[source]

Bases: holoviews.plotting.mpl.element.ElementPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

padding = param.ClassSelector(class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=0)

Fraction by which to increase auto-ranged extents to make datapoints more visible around borders. To compute padding, the axis whose screen size is largest is chosen, and the range of that axis is increased by the specified fraction along each axis. Other axes are then padded ensuring that the amount of screen space devoted to padding is equal for all axes. If specified as a tuple, the int or float values in the tuple will be used for padding in each axis, in order (x,y or x,y,z). For example, for padding=0.2 on a 800x800-pixel plot, an x-axis with the range [0,10] will be padded by 20% to be [-1,11], while a y-axis with a range [0,1000] will be padded to be [-100,1100], which should make the padding be approximately the same number of pixels. But if the same plot is changed to have a height of only 200, the y-range will then be [-400,1400] so that the y-axis padding will still match that of the x-axis. It is also possible to declare non-equal padding value for the lower and upper bound of an axis by supplying nested tuples, e.g. padding=(0.1, (0, 0.1)) will pad the x-axis lower and upper bound as well as the y-axis upper bound by a fraction of 0.1 while the y-axis lower bound is not padded at all.

show_legend = param.Boolean(bounds=(0, 1), default=False)

Whether to show legend for the plot.

aspect = param.Parameter(default=’equal’)

Raster elements respect the aspect ratio of the Images by default but may be set to an explicit aspect ratio or to ‘square’.

situate_axes = param.Boolean(bounds=(0, 1), default=True)

Whether to situate the image relative to other plots.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')[source]

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.raster.RasterGridPlot(layout, keys=None, dimensions=None, create_axes=False, ranges=None, layout_num=1, **params)[source]

Bases: holoviews.plotting.mpl.plot.GridPlot, holoviews.plotting.mpl.element.OverlayPlot

RasterGridPlot evenly spaces out plots of individual projections on a grid, even when they differ in size. Since this class uses a single axis to generate all the individual plots it is much faster than the equivalent using subplots.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.mpl.plot.CompositePlot: shared_axes

holoviews.plotting.mpl.plot.GridPlot: aspect, shared_xaxis, shared_yaxis, show_legend, xaxis, yaxis, xrotation, yrotation

apply_ranges = param.Parameter(default=True)

Whether to compute the plot bounds from the data itself.

apply_extents = param.Parameter(default=True)

Whether to apply extent overrides on the Elements

bgcolor = param.Parameter()

If set bgcolor overrides the background color of the axis.

default_span = param.Parameter(default=2.0)

Defines the span of an axis if the axis range is zero, i.e. if the lower and upper end of an axis are equal or no range is defined at all. For example if there is a single datapoint at 0 a default_span of 2.0 will result in axis ranges spanning from -1 to 1.

hooks = param.Parameter(default=[])

Optional list of hooks called when finalizing a plot. The hook is passed the plot object and the displayed element, and other plotting handles can be accessed via plot.handles.

invert_axes = param.Parameter(default=False)

Whether to invert the x- and y-axis

invert_xaxis = param.Parameter(default=False)

Whether to invert the plot x-axis.

invert_yaxis = param.Parameter(default=False)

Whether to invert the plot y-axis.

finalize_hooks = param.Parameter(default=[])

Deprecated; use hooks options instead.

logx = param.Parameter(default=False)

Whether the x-axis of the plot will be a log axis.

logy = param.Parameter(default=False)

Whether the y-axis of the plot will be a log axis.

padding = param.Number(default=0.1, inclusive_bounds=(True, True))

The amount of padding as a fraction of the total Grid size

show_grid = param.Parameter(default=False)

Whether to show a Cartesian grid on the plot.

xlabel = param.Parameter()

An explicit override of the x-axis label, if set takes precedence over the dimension label.

ylabel = param.Parameter()

An explicit override of the y-axis label, if set takes precedence over the dimension label.

xlim = param.Parameter(default=(nan, nan))

User-specified x-axis range limits for the plot, as a tuple (low,high). If specified, takes precedence over data and dimension ranges.

ylim = param.Parameter(default=(nan, nan))

User-specified x-axis range limits for the plot, as a tuple (low,high). If specified, takes precedence over data and dimension ranges.

zlim = param.Parameter(default=(nan, nan))

User-specified z-axis range limits for the plot, as a tuple (low,high). If specified, takes precedence over data and dimension ranges.

xticks = param.Parameter()

Ticks along x-axis specified as an integer, explicit list of tick locations, or bokeh Ticker object. If set to None default bokeh ticking behavior is applied.

yticks = param.Parameter()

Ticks along y-axis specified as an integer, explicit list of tick locations, or bokeh Ticker object. If set to None default bokeh ticking behavior is applied.

batched = param.Parameter(default=True)

Whether to plot Elements NdOverlay in a batched plotting call if possible. Disables legends and zorder may not be preserved.

legend_limit = param.Parameter(default=25)

Number of rendered glyphs before legends are disabled.

style_grouping = param.Parameter(default=2)

The length of the type.group.label spec that will be used to group Elements into style groups. A style_grouping value of 1 will group just by type, a value of 2 will group by type and group, and a value of 3 will group by the full specification.

apply_ticks = param.Parameter(default=True)

Whether to apply custom ticks.

data_aspect = param.Parameter()

Defines the aspect of the axis scaling, i.e. the ratio of y-unit to x-unit.

invert_zaxis = param.Parameter(default=False)

Whether to invert the plot z-axis.

labelled = param.Parameter(default=[‘x’, ‘y’])

Whether to plot the ‘x’ and ‘y’ labels.

logz = param.Parameter(default=False)

Whether to apply log scaling to the y-axis of the Chart.

xformatter = param.Parameter()

Formatter for ticks along the x-axis.

yformatter = param.Parameter()

Formatter for ticks along the y-axis.

zformatter = param.Parameter()

Formatter for ticks along the z-axis.

zaxis = param.Parameter(default=True)

Whether to display the z-axis.

zlabel = param.Parameter()

An explicit override of the z-axis label, if set takes precedence over the dimension label.

zrotation = param.Parameter(default=0)

Rotation angle of the zticks.

zticks = param.Parameter()

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.

legend_cols = param.Parameter()

Number of legend columns in the legend.

legend_position = param.Parameter(default=’inner’)

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 = param.Parameter(default={})

Allows setting specific styling options for the colorbar.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(view, ranges, range_type='combined')[source]

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.raster.RasterPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.raster.RasterBasePlot, holoviews.plotting.mpl.element.ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.raster.RasterBasePlot: padding, show_legend, aspect, situate_axes

clipping_colors = param.Dict(class_=<class ‘dict’>, default={‘NaN’: ‘transparent’})

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.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.


renderer Module

Inheritance diagram of holoviews.plotting.mpl.renderer
class holoviews.plotting.mpl.renderer.MPLRenderer(*args, **params)[source]

Bases: holoviews.plotting.renderer.Renderer

Exporter used to render data from matplotlib, either to a stream or directly to file.

The __call__ method renders an HoloViews component to raw data of a specified matplotlib format. The save method is the corresponding method for saving a HoloViews objects to disk.

The save_fig and save_anim methods are used to save matplotlib figure and animation objects. These match the two primary return types of plotting class implemented with matplotlib.

Parameters inherited from:

holoviews.plotting.renderer.Renderer: key_fn, info_fn, center, fps, size, widget_location, widget_mode, css, post_render_hooks

backend = param.String(default=’matplotlib’)

The backend name.

dpi = param.Integer(default=72, inclusive_bounds=(True, True))

The render resolution in dpi (dots per inch)

fig = param.ObjectSelector(default=’auto’, objects=[‘png’, ‘svg’, ‘pdf’, ‘pgf’, ‘html’, None, ‘auto’])

Output render format for static figures. If None, no figure rendering will occur.

holomap = param.ObjectSelector(default=’auto’, objects=[‘widgets’, ‘scrubber’, ‘webm’, ‘mp4’, ‘gif’, None, ‘auto’])

Output render multi-frame (typically animated) format. If None, no multi-frame rendering will occur.

mode = param.ObjectSelector(default=’default’, objects=[‘default’])

Whether to render the object in regular or server mode. In server mode a bokeh Document will be returned which can be served as a bokeh server app. By default renders all output is rendered to HTML.

interactive = param.Boolean(bounds=(0, 1), default=False)

Whether to enable interactive plotting allowing interactive plotting with explicitly calling show.

app(plot, show=False, new_window=False, websocket_origin=None, port=0)

Creates a bokeh app from a HoloViews object or plot. By default simply attaches the plot to bokeh’s curdoc and returns the Document, if show option is supplied creates an Application instance and displays it either in a browser window or inline if notebook extension has been loaded. Using the new_window option the app may be displayed in a new browser tab once the notebook extension has been loaded. A websocket origin is required when launching from an existing tornado server (such as the notebook) and it is not on the default port (‘localhost:8888’).

comm_manager

alias of pyviz_comms.CommManager

components(obj, fmt=None, comm=True, **kwargs)

Returns data and metadata dictionaries containing HTML and JS components to include render in app, notebook, or standalone document.

classmethod encode(entry)

Classmethod that applies conditional encoding based on mime-type. Given an entry as returned by __call__ return the data in the appropriate encoding.

export_widgets(obj, filename, fmt=None, template=None, json=False, json_path='', **kwargs)

Render and export object as a widget to a static HTML file. Allows supplying a custom template formatting string with fields to interpolate ‘js’, ‘css’ and the main ‘html’ containing the widget. Also provides options to export widget data to a json file in the supplied json_path (defaults to current path).

get_plot(obj, doc=None, renderer=None, comm=None, **kwargs)

Given a HoloViews Viewable return a corresponding plot instance.

get_plot_state(obj, renderer=None, **kwargs)

Given a HoloViews Viewable return a corresponding plot state.

html(obj, fmt=None, css=None, resources='CDN', **kwargs)

Renders plot or data structure and wraps the output in HTML. The comm argument defines whether the HTML output includes code to initialize a Comm, if the plot supplies one.

classmethod html_assets(core=True, extras=True, backends=None, script=False)

Deprecated: No longer needed

instance(**params)

Return an instance of this class, copying parameters from any existing instance provided.

classmethod load_nb(inline=True)[source]

Initialize matplotlib backend

classmethod plot_options(obj, percent_size)[source]

Given a holoviews object and a percentage size, apply heuristics to compute a suitable figure size. For instance, scaling layouts and grids linearly can result in unwieldy figure sizes when there are a large number of elements. As ad hoc heuristics are used, this functionality is kept separate from the plotting classes themselves.

Used by the IPython Notebook display hooks and the save utility. Note that this can be overridden explicitly per object using the fig_size and size plot options.

classmethod plotting_class(obj)

Given an object or Element class, return the suitable plotting class needed to render it with the current renderer.

pprint(imports=None, prefix='\n ', unknown_value='<?>', qualify=False, separator='')

Same as Parameterized.pprint, except that X.classname(Y is replaced with X.classname.instance(Y

save(obj, basename, fmt='auto', key={}, info={}, options=None, resources='inline', title=None, **kwargs)

Save a HoloViews object to file, either using an explicitly supplied format or to the appropriate default.

script_repr(imports=[], prefix=' ')

Same as Parameterized.script_repr, except that X.classname(Y is replaced with X.classname.instance(Y

server_doc(obj, doc=None)

Get a bokeh Document with the plot attached. May supply an existing doc, otherwise bokeh.io.curdoc() is used to attach the plot to the global document instance.

show(obj)[source]

Renders the supplied object and displays it using the active GUI backend.

classmethod state()[source]

Context manager to handle global state for a backend, allowing Plot classes to temporarily override that state.

static_html(obj, fmt=None, template=None)

Generates a static HTML with the rendered object in the supplied format. Allows supplying a template formatting string with fields to interpolate ‘js’, ‘css’ and the main ‘html’.

classmethod validate(options)

Validate an options dictionary for the renderer.

class holoviews.plotting.mpl.renderer.OutputWarning(*, fig, holomap, widgets, fps, max_frames, size, dpi, filename, info, css, widget_location)[source]

Bases: param.parameterized.Parameterized


sankey Module

Inheritance diagram of holoviews.plotting.mpl.sankey
class holoviews.plotting.mpl.sankey.SankeyPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.graphs.GraphPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.graphs.GraphPlot: arrowhead_length, directed, edge_color_index

color_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>), default=2)

Index of the dimension from which the node labels will be drawn

labels = param.ClassSelector(class_=(<class ‘str’>, <class ‘holoviews.util.transform.dim’>))

The dimension or dimension value transform used to draw labels from.

show_values = param.Boolean(bounds=(0, 1), default=True)

Whether to show the values.

label_position = param.ObjectSelector(default=’right’, objects=[‘left’, ‘right’])

Whether node labels should be placed to the left or right.

node_width = param.Number(default=15, inclusive_bounds=(True, True))

Width of the nodes.

node_padding = param.Integer(inclusive_bounds=(True, True))

Number of pixels of padding relative to the bounds.

iterations = param.Integer(default=32, inclusive_bounds=(True, True))

Number of iterations to run the layout algorithm.

node_sort = param.Boolean(bounds=(0, 1), default=True)

Sort nodes in ascending breadth.

label_index = param.ClassSelector(class_=(<class ‘str’>, <class ‘int’>), default=2)

Index of the dimension from which the node labels will be drawn

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')[source]

A Chord plot is always drawn on a unit circle.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)[source]

Update the elements of the plot.


stats Module

Inheritance diagram of holoviews.plotting.mpl.stats
class holoviews.plotting.mpl.stats.BivariatePlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.path.PolygonPlot

Bivariate plot visualizes two-dimensional kernel density estimates. Additionally, by enabling the joint option, the marginals distributions can be plotted alongside each axis (does not animate or compose).

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.element.ColorbarPlot: clabel, clim, cformatter, colorbar, colorbar_opts, color_levels, clipping_colors, cbar_padding, cbar_ticks, cbar_width, cbar_extend, symmetric

holoviews.plotting.mpl.path.PathPlot: aspect

holoviews.plotting.mpl.path.ContourPlot: color_index

holoviews.plotting.mpl.path.PolygonPlot: show_legend

bandwidth = param.Number(inclusive_bounds=(True, True))

The bandwidth of the kernel for the density estimate.

cut = param.Number(default=3, inclusive_bounds=(True, True))

Draw the estimate to cut * bw from the extreme data points.

filled = param.Boolean(bounds=(0, 1), default=False)

Whether the bivariate contours should be filled.

levels = param.ClassSelector(class_=(<class ‘list’>, <class ‘int’>), default=10)

A list of scalar values used to specify the contour levels.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.stats.BoxPlot(element, **params)[source]

Bases: holoviews.plotting.mpl.chart.ChartPlot

BoxPlot plots the ErrorBar Element type and supporting both horizontal and vertical error bars via the ‘horizontal’ plot option.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')[source]

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()[source]

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.stats.DistributionPlot(element, **params)[source]

Bases: holoviews.plotting.mpl.chart.AreaPlot

DistributionPlot visualizes a distribution of values as a KDE.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.chart.AreaPlot: padding, show_legend

bandwidth = param.Number(inclusive_bounds=(True, True))

The bandwidth of the kernel for the density estimate.

cut = param.Number(default=3, inclusive_bounds=(True, True))

Draw the estimate to cut * bw from the extreme data points.

filled = param.Boolean(bounds=(0, 1), default=True)

Whether the bivariate contours should be filled.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_data, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.stats.SideBoxPlot(*args, **kwargs)[source]

Bases: holoviews.plotting.mpl.plot.AdjoinedPlot, holoviews.plotting.mpl.stats.BoxPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

holoviews.plotting.mpl.plot.AdjoinedPlot: show_title, aspect, subplot_size, show_xlabel

bgcolor = param.Parameter(default=(1, 1, 1, 0))

Make plot background invisible.

xaxis = param.ObjectSelector(default=’bare’, objects=[‘top’, ‘bottom’, ‘bare’, ‘top-bare’, ‘bottom-bare’, None])

Whether and where to display the xaxis, bare options allow suppressing all axis labels including ticks and xlabel. Valid options are ‘top’, ‘bottom’, ‘bare’, ‘top-bare’ and ‘bottom-bare’.

yaxis = param.ObjectSelector(default=’bare’, objects=[‘left’, ‘right’, ‘bare’, ‘left-bare’, ‘right-bare’, None])

Whether and where to display the yaxis, bare options allow suppressing all axis labels including ticks and ylabel. Valid options are ‘left’, ‘right’, ‘bare’ ‘left-bare’ and ‘right-bare’.

border_size = param.Number(default=0, inclusive_bounds=(True, True))

The size of the border expressed as a fraction of the main plot.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.

class holoviews.plotting.mpl.stats.ViolinPlot(element, **params)[source]

Bases: holoviews.plotting.mpl.stats.BoxPlot

BoxPlot plots the ErrorBar Element type and supporting both horizontal and vertical error bars via the ‘horizontal’ plot option.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

bandwidth = param.Number(inclusive_bounds=(True, True))

Allows supplying explicit bandwidth value rather than relying on scott or silverman method.

inner = param.ObjectSelector(default=’box’, objects=[‘box’, ‘medians’, None])

Inner visual indicator for distribution values: * box - A small box plot * stick - Lines indicating each sample value * quartiles - Indicates first, second and third quartiles

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined')

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)[source]

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()[source]

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axis, element, ranges, style)

Update the elements of the plot.


tabular Module

Inheritance diagram of holoviews.plotting.mpl.tabular
class holoviews.plotting.mpl.tabular.TablePlot(table, **params)[source]

Bases: holoviews.plotting.mpl.element.ElementPlot

A TablePlot can plot both TableViews and ViewMaps which display as either a single static table or as an animated table respectively.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, title, title_format, normalize

holoviews.plotting.mpl.plot.MPLPlot: projection, fig_alpha, fig_bounds, fig_inches, fig_latex, fig_rcparams, fig_size, initial_hooks, sublabel_format, sublabel_position, sublabel_size, show_frame

holoviews.plotting.plot.GenericElementPlot: apply_ranges, apply_extents, bgcolor, default_span, hooks, invert_axes, invert_xaxis, invert_yaxis, finalize_hooks, logx, logy, padding, show_legend, show_grid, xaxis, yaxis, xlabel, ylabel, xlim, ylim, zlim, xrotation, yrotation, xticks, yticks

holoviews.plotting.mpl.element.ElementPlot: apply_ticks, aspect, data_aspect, invert_zaxis, labelled, logz, xformatter, yformatter, zformatter, zaxis, zlabel, zrotation, zticks

border = param.Number(bounds=(0.0, 0.5), default=0.05, inclusive_bounds=(True, True))

The fraction of the plot that should be empty around the edges.

float_precision = param.Integer(default=3, inclusive_bounds=(True, True))

The floating point precision to use when printing float numeric data types.

max_value_len = param.Integer(default=20, inclusive_bounds=(True, True))

The maximum allowable string length of a value shown in any table cell. Any strings longer than this length will be truncated.

max_font_size = param.Integer(default=12, inclusive_bounds=(True, True))

The largest allowable font size for the text in each table cell.

max_rows = param.Integer(default=15, inclusive_bounds=(True, True))

The maximum number of Table rows before the table is summarized.

font_types = param.Dict(class_=<class ‘dict’>, default={‘heading’: <matplotlib.font_manager.FontProperties object at 0x7faf13182f90>})

The font style used for heading labels used for emphasis.

anim(start=0, stop=None, fps=30)

Method to return a matplotlib animation. The start and stop frames may be specified as well as the fps.

cleanup()

Cleans up references to the plot on the attached Stream subscribers.

compute_ranges(obj, key, ranges)

Given an object, a specific key, and the normalization options, this method will find the specified normalization options on the appropriate OptionTree, group the elements according to the selected normalization option (i.e. either per frame or over the whole animation) and finally compute the dimension ranges in each group. The new set of ranges is returned.

get_aspect(xspan, yspan)

Computes the aspect ratio of the plot

get_extents(element, ranges, range_type='combined', xdim=None, ydim=None, zdim=None)

Gets the extents for the axes from the current Element. The globally computed ranges can optionally override the extents.

The extents are computed by combining the data ranges, extents and dimension ranges. Each of these can be obtained individually by setting the range_type to one of:

  • ‘data’: Just the data ranges

  • ‘extents’: Element.extents

  • ‘soft’: Dimension.soft_range values

  • ‘hard’: Dimension.range values

To obtain the combined range, which includes range padding the default may be used:

  • ‘combined’: All the range types combined and padding applied

This allows Overlay plots to obtain each range and combine them appropriately for all the objects in the overlay.

get_padding(obj, extents)

Computes padding along the axes taking into account the plot aspect.

get_zorder(overlay, key, el)

Computes the z-order of element in the NdOverlay taking into account possible batching of elements.

init_artists(ax, plot_args, plot_kwargs)

Initializes the artist based on the plot method declared on the plot.

matches(spec)

Matches a specification against the current Plot.

push()

Pushes plot updates to the frontend.

refresh(**kwargs)

Refreshes the plot by rerendering it and then pushing the updated data if the plot has an associated Comm.

set_root(root)

Sets the root model on all subplots.

property state

The plotting state that gets updated via the update method and used by the renderer to generate output.

teardown_handles()

If no custom update_handles method is supplied this method is called to tear down any previous handles before replacing them.

traverse(fn=None, specs=None, full_breadth=True)

Traverses any nested DimensionedPlot returning a list of all plots that match the specs. The specs should be supplied as a list of either Plot types or callables, which should return a boolean given the plot class.

update(key)

Update the internal state of the Plot to represent the given key tuple (where integers represent frames). Returns this state.

update_handles(key, axes, element, ranges, style)[source]

Update the elements of the plot.


util Module

Inheritance diagram of holoviews.plotting.mpl.util
class holoviews.plotting.mpl.util.CFTimeConverter[source]

Bases: matplotlib.dates.DateConverter

Defines conversions for cftime types by extending nc_time_axis.

static axisinfo(unit, axis)

Return the AxisInfo for unit.

unit is a tzinfo instance or None. The axis argument is required but not used.

classmethod convert(value, unit, axis)[source]

If value is not already a number or sequence of numbers, convert it with date2num().

The unit and axis arguments are not used.

static default_units(x, axis)

Return the tzinfo instance of x or of its first element, or None

static is_numlike(x)

The Matplotlib datalim, autoscaling, locators etc work with scalars which are the units converted to floats given the current unit. The converter may be passed these floats, or arrays of them, even when units are set.

holoviews.plotting.mpl.util.axis_overlap(ax1, ax2)[source]

Tests whether two axes overlap vertically

holoviews.plotting.mpl.util.filter_styles(style, group, other_groups, blacklist=[])[source]

Filters styles which are specific to a particular artist, e.g. for a GraphPlot this will filter options specific to the nodes and edges.

style: dict

Dictionary of styles and values

group: str

Group within the styles to filter for

other_groups: list

Other groups to filter out

blacklist: list (optional)

List of options to filter out

filtered: dict

Filtered dictionary of styles

holoviews.plotting.mpl.util.fix_aspect(fig, nrows, ncols, title=None, extra_artists=[], vspace=0.2, hspace=0.2)[source]

Calculate heights and widths of axes and adjust the size of the figure to match the aspect.

holoviews.plotting.mpl.util.get_raster_array(image)[source]

Return the array data from any Raster or Image type

holoviews.plotting.mpl.util.get_tight_bbox(fig, bbox_extra_artists=[], pad=None)[source]

Compute a tight bounding box around all the artists in the figure.

holoviews.plotting.mpl.util.is_color(color)[source]

Checks if supplied object is a valid color spec.

holoviews.plotting.mpl.util.polygons_to_path_patches(element)[source]

Converts Polygons into list of lists of matplotlib.patches.PathPatch objects including any specified holes. Each list represents one (multi-)polygon.

holoviews.plotting.mpl.util.resolve_rows(rows)[source]

Recursively iterate over lists of axes merging them by their vertical overlap leaving a list of rows.

holoviews.plotting.mpl.util.ring_coding(array)[source]

Produces matplotlib Path codes for exterior and interior rings of a polygon geometry.

holoviews.plotting.mpl.util.validate(style, value, vectorized=True)[source]

Validates a style and associated value.

style: str

The style to validate (e.g. ‘color’, ‘size’ or ‘marker’)

value:

The style value to validate

vectorized: bool

Whether validator should allow vectorized setting

valid: boolean or None

If validation is supported returns boolean, otherwise None

holoviews.plotting.mpl.util.wrap_formatter(formatter)[source]

Wraps formatting function or string in appropriate matplotlib formatter type.