holoviews.bokeh Package#


bokeh Package#


annotation Module#

class holoviews.plotting.bokeh.annotation.ArrowPlot(element, plot=None, **params)[source]#

Bases: CompositeElementPlot, AnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges=None, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

selection_display = None#
set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.BoxAnnotationPlot(element, plot=None, **params)[source]#

Bases: ElementPlot, AnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

apply_ranges = param.Boolean(allow_refs=False, default=False, label=’Apply ranges’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16f76be10>)

Whether to include the annotation in axis range calculations.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

selection_display = None#
set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.DivPlot(element, plot=None, **params)[source]#

Bases: BokehPlot, GenericElementPlot, AnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontsize, fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format, toolbar

hooks = param.HookList(allow_refs=False, bounds=(0, None), default=[], label=’Hooks’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16f373b90>)

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.

width = param.Number(allow_refs=False, bounds=(0, None), default=300, inclusive_bounds=(True, True), label=’Width’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16f71ebd0>)

The width of the component (in pixels). This can be either fixed or preferred width, depending on width sizing policy.

height = param.Number(allow_refs=False, bounds=(0, None), default=300, inclusive_bounds=(True, True), label=’Height’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16f71f010>)

The height of the component (in pixels). This can be either fixed or preferred height, depending on height sizing policy.

sizing_mode = param.ObjectSelector(allow_refs=False, label=’Sizing mode’, names={}, nested_refs=False, objects=[‘fixed’, ‘stretch_width’, ‘stretch_height’, ‘stretch_both’, ‘scale_width’, ‘scale_height’, ‘scale_both’, None], rx=<param.reactive.reactive_ops object at 0x16f71e490>)

How the component should size itself. * “fixed” : Component is not responsive. It will retain its original width and height regardless of any subsequent browser window resize events. * “stretch_width” Component will responsively resize to stretch to the available width, without maintaining any aspect ratio. The height of the component depends on the type of the component and may be fixed or fit to component’s contents. * “stretch_height” Component will responsively resize to stretch to the available height, without maintaining any aspect ratio. The width of the component depends on the type of the component and may be fixed or fit to component’s contents. * “stretch_both” Component is completely responsive, independently in width and height, and will occupy all the available horizontal and vertical space, even if this changes the aspect ratio of the component. * “scale_width” Component will responsively resize to stretch to the available width, while maintaining the original or provided aspect ratio. * “scale_height” Component will responsively resize to stretch to the available height, while maintaining the original or provided aspect ratio. * “scale_both” Component will responsively resize to both the available width and height, while maintaining the original or provided aspect ratio.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

get_aspect(xspan, yspan)[source]#

Should define the aspect ratio of the plot.

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

selection_display = None#
set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(key, ranges=None, plot=None)[source]#

Updates an existing plot with data corresponding to the key.

class holoviews.plotting.bokeh.annotation.HLinesAnnotationPlot(element, **kwargs)[source]#

Bases: _SyntheticAnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

holoviews.plotting.bokeh.annotation._SyntheticAnnotationPlot: apply_ranges

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges=None, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.HSpansAnnotationPlot(element, **kwargs)[source]#

Bases: _SyntheticAnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

holoviews.plotting.bokeh.annotation._SyntheticAnnotationPlot: apply_ranges

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges=None, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.LabelsPlot(element, plot=None, **params)[source]#

Bases: ColorbarPlot, AnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

show_legend = param.Boolean(allow_refs=False, default=False, label=’Show legend’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16fcc38d0>)

Whether to show legend for the plot.

xoffset = param.Number(allow_None=True, allow_refs=False, inclusive_bounds=(True, True), label=’Xoffset’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16fccb490>)

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

yoffset = param.Number(allow_None=True, allow_refs=False, inclusive_bounds=(True, True), label=’Yoffset’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16fccbb50>)

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

color_index = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘int’>), label=’Color index’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16fcca6d0>)

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

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.LineAnnotationPlot(element, plot=None, **params)[source]#

Bases: ElementPlot, AnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

apply_ranges = param.Boolean(allow_refs=False, default=False, label=’Apply ranges’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16fb02e10>)

Whether to include the annotation in axis range calculations.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges=None, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

selection_display = None#
set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.SlopePlot(element, plot=None, **params)[source]#

Bases: ElementPlot, AnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges=None, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

selection_display = None#
set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.SplinePlot(element, plot=None, **params)[source]#

Bases: ElementPlot, AnnotationPlot

Draw the supplied Spline annotation (see Spline docstring). Does not support matplotlib Path codes.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

selection_display = None#
set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.TextPlot(element, plot=None, **params)[source]#

Bases: ElementPlot, AnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges=None, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

selection_display = None#
set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.VLinesAnnotationPlot(element, **kwargs)[source]#

Bases: _SyntheticAnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

holoviews.plotting.bokeh.annotation._SyntheticAnnotationPlot: apply_ranges

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges=None, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.annotation.VSpansAnnotationPlot(element, **kwargs)[source]#

Bases: _SyntheticAnnotationPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

holoviews.plotting.bokeh.annotation._SyntheticAnnotationPlot: apply_ranges

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges=None, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.


callbacks Module#

class holoviews.plotting.bokeh.callbacks.BoundsCallback(plot, streams, source, **params)[source]#

Bases: PopupMixin, Callback

Returns the bounds of a box_select tool.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.BoundsXCallback(plot, streams, source, **params)[source]#

Bases: Callback

Returns the bounds of a xbox_select tool.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.BoundsYCallback(plot, streams, source, **params)[source]#

Bases: Callback

Returns the bounds of a ybox_select tool.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.BoxEditCallback(plot, streams, source, **params)[source]#

Bases: GlyphDrawCallback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.CDSCallback(plot, streams, source, **params)[source]#

Bases: Callback

A Stream callback that syncs the data on a bokeh ColumnDataSource model with Python.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.Callback(plot, streams, source, **params)[source]#

Bases: object

Provides a baseclass to define callbacks, which return data from bokeh model callbacks, events and attribute changes. The callback then makes this data available to any streams attached to it.

The definition of a callback consists of a number of components:

  • modelsDefines which bokeh models the callback will be

    attached on referencing the model by its key in the plots handles, e.g. this could be the x_range, y_range, plot, a plotting tool or any other bokeh mode.

  • attributesThe attributes define which attributes to send

    back to Python. They are defined as a dictionary mapping between the name under which the variable is made available to Python and the specification of the attribute. The specification should start with the variable name that is to be accessed and the location of the attribute separated by periods. All models defined by the models and can be addressed in this way, e.g. to get the start of the x_range as ‘x’ you can supply {‘x’: ‘x_range.attributes.start’}. Additionally certain handles additionally make the cb_obj variables available containing additional information about the event.

  • on_eventsIf the Callback should listen to bokeh events this

    should declare the types of event as a list (optional)

  • on_changesIf the Callback should listen to model attribute

    changes on the defined models (optional)

If either on_events or on_changes are declared the Callback will be registered using the on_event or on_change machinery, otherwise it will be treated as a regular callback on the model. The callback can also define a _process_msg method, which can modify the data sent by the callback before it is passed to the streams.

A callback supports three different throttling modes:

  • adaptive (default): The callback adapts the throttling timeout depending on the rolling mean of the time taken to process each message. The rolling window is controlled by the adaptive_window value.

  • throttle: Uses the fixed throttle_timeout as the minimum amount of time between events.

  • debounce: Processes the message only when no new event has been received within the throttle_timeout duration.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.CurveEditCallback(plot, streams, source, **params)[source]#

Bases: GlyphDrawCallback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.DoubleTapCallback(plot, streams, source, **params)[source]#

Bases: TapCallback

Returns the mouse x/y-position on doubletap event.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.DrawCallback(*args, **kwargs)[source]#

Bases: PointerXYCallback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.FreehandDrawCallback(plot, streams, source, **params)[source]#

Bases: PolyDrawCallback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.GlyphDrawCallback(plot, streams, source, **params)[source]#

Bases: CDSCallback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.LassoCallback(plot, streams, source, **params)[source]#

Bases: PopupMixin, Callback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.MouseEnterCallback(plot, streams, source, **params)[source]#

Bases: PointerXYCallback

Returns the mouse x/y-position on mouseenter event, i.e. when mouse enters the plot canvas.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.MouseLeaveCallback(plot, streams, source, **params)[source]#

Bases: PointerXYCallback

Returns the mouse x/y-position on mouseleave event, i.e. when mouse leaves the plot canvas.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.MultiAxisTapCallback(plot, streams, source, **params)[source]#

Bases: TapCallback

Returns the mouse x/y-positions on tap event.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.PanEndCallback(plot, streams, source, **params)[source]#

Bases: TapCallback

Returns the mouse x/y-position of a pan end event.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.PlotSizeCallback(plot, streams, source, **params)[source]#

Bases: Callback

Returns the actual width and height of a plot once the layout solver has executed.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.PointDrawCallback(plot, streams, source, **params)[source]#

Bases: GlyphDrawCallback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.PointerXCallback(plot, streams, source, **params)[source]#

Bases: PointerXYCallback

Returns the mouse x-position on mousemove event.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.PointerXYCallback(plot, streams, source, **params)[source]#

Bases: Callback

Returns the mouse x/y-position on mousemove event.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.PointerYCallback(plot, streams, source, **params)[source]#

Bases: PointerXYCallback

Returns the mouse x/y-position on mousemove event.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.PolyDrawCallback(plot, streams, source, **params)[source]#

Bases: GlyphDrawCallback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.PolyEditCallback(plot, streams, source, **params)[source]#

Bases: PolyDrawCallback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.PressUpCallback(plot, streams, source, **params)[source]#

Bases: TapCallback

Returns the mouse x/y-position of a pressup mouse event.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.RangeXCallback(plot, streams, source, **params)[source]#

Bases: RangeXYCallback

Returns the x-axis range of a plot.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.RangeXYCallback(plot, streams, source, **params)[source]#

Bases: Callback

Returns the x/y-axis ranges of a plot.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.RangeYCallback(plot, streams, source, **params)[source]#

Bases: RangeXYCallback

Returns the y-axis range of a plot.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.ResetCallback(plot, streams, source, **params)[source]#

Bases: Callback

Signals the Reset stream if an event has been triggered.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.SelectModeCallback(plot, streams, source, **params)[source]#

Bases: Callback

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.Selection1DCallback(plot, streams, source, **params)[source]#

Bases: PopupMixin, Callback

Returns the current selection on a ColumnDataSource.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.SelectionXYCallback(plot, streams, source, **params)[source]#

Bases: BoundsCallback

Converts a bounds selection to numeric or categorical x-range and y-range selections.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.SingleTapCallback(plot, streams, source, **params)[source]#

Bases: TapCallback

Returns the mouse x/y-position on tap event.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.

class holoviews.plotting.bokeh.callbacks.TapCallback(plot, streams, source, **params)[source]#

Bases: PopupMixin, PointerXYCallback

Returns the mouse x/y-position on tap event.

Note: As of bokeh 0.12.5, there is no way to distinguish the individual tap events within a doubletap event.

async on_change(attr, old, new)[source]#

Process change events adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async on_event(event)[source]#

Process bokeh UIEvents adding timeout to process multiple concerted value change at once rather than firing off multiple plot updates.

async process_on_event(timeout=None)[source]#

Trigger callback change event and triggering corresponding streams.

classmethod resolve_attr_spec(spec, cb_obj, model=None)[source]#

Resolves a Callback attribute specification looking the corresponding attribute up on the cb_obj, which should be a bokeh model. If not model is supplied cb_obj is assumed to be the same as the model.

set_callback(handle)[source]#

Set up on_change events for bokeh server interactions.


chart Module#

class holoviews.plotting.bokeh.chart.AreaPlot(element, plot=None, **params)[source]#

Bases: AreaMixin, SpreadPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

padding = param.ClassSelector(allow_refs=False, class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=(0, 0.1), label=’Padding’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170c546d0>)

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.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.BarPlot(element, plot=None, **params)[source]#

Bases: BarsMixin, ColorbarPlot, LegendPlot

BarPlot allows generating single- or multi-category bar Charts, by selecting which key dimensions are mapped onto separate groups, categories and stacks.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.LegendPlot: legend_cols, legend_labels, legend_muted, legend_offset, legend_position, legend_opts

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

multi_level = param.Boolean(allow_refs=False, default=True, label=’Multi level’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170c0ce50>)

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

stacked = param.Boolean(allow_refs=False, default=False, label=’Stacked’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170c01510>)

Whether the bars should be stacked or grouped.

color_index = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘int’>), label=’Color index’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170c00910>)

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

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

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

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)[source]#

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

get_stack(xvals, yvals, baselines, sign='positive')[source]#

Iterates over a x- and y-values in a stack layer and appropriately offsets the layer on top of the previous layer.

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.CurvePlot(element, plot=None, **params)[source]#

Bases: ElementPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

padding = param.ClassSelector(allow_refs=False, class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=(0, 0.1), label=’Padding’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170d4ae10>)

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.

interpolation = param.ObjectSelector(allow_refs=False, default=’linear’, label=’Interpolation’, names={}, nested_refs=False, objects=[‘linear’, ‘steps-mid’, ‘steps-pre’, ‘steps-post’], rx=<param.reactive.reactive_ops object at 0x170d4b590>)

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

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.ErrorPlot(element, plot=None, **params)[source]#

Bases: ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

selected = param.List(allow_None=True, allow_refs=False, bounds=(0, None), label=’Selected’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170dba650>)

The current selection as a list of integers corresponding to the selected items.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.HistogramPlot(element, plot=None, **params)[source]#

Bases: ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.PointPlot(element, plot=None, **params)[source]#

Bases: LegendPlot, ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

holoviews.plotting.bokeh.element.LegendPlot: legend_cols, legend_labels, legend_muted, legend_offset, legend_position, legend_opts

jitter = param.Number(allow_None=True, allow_refs=False, bounds=(0, None), inclusive_bounds=(True, True), label=’Jitter’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170ea6710>)

The amount of jitter to apply to offset the points along the x-axis.

selected = param.List(allow_None=True, allow_refs=False, bounds=(0, None), label=’Selected’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170e9c1d0>)

The current selection as a list of integers corresponding to the selected items.

color_index = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘int’>), label=’Color index’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170ea5f10>)

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

size_index = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘int’>), label=’Size index’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170ea6250>)

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

scaling_method = param.ObjectSelector(allow_refs=False, default=’area’, label=’Scaling method’, names={}, nested_refs=False, objects=[‘width’, ‘area’], rx=<param.reactive.reactive_ops object at 0x170ea5f10>)

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

scaling_factor = param.Number(allow_refs=False, bounds=(0, None), default=1, inclusive_bounds=(True, True), label=’Scaling factor’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170e9c110>)

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(allow_refs=False, default=<ufunc ‘absolute’>, label=’Size fn’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170529810>)

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

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.SideHistogramPlot(*args, **kwargs)[source]#

Bases: HistogramPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

show_title = param.Boolean(allow_refs=False, default=False, label=’Show title’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170f2aad0>)

Whether to display the plot title.

width = param.Integer(allow_refs=False, bounds=(0, None), default=125, inclusive_bounds=(True, True), label=’Width’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170f0c710>)

The width of the plot

height = param.Integer(allow_refs=False, bounds=(0, None), default=125, inclusive_bounds=(True, True), label=’Height’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170f0cdd0>)

The height of the plot

default_tools = param.List(allow_refs=False, bounds=(0, None), default=[‘save’, ‘pan’, ‘wheel_zoom’, ‘box_zoom’, ‘reset’], label=’Default tools’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170f2bf10>)

A list of plugin tools to use on the plot.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.SideSpikesPlot(element, plot=None, **params)[source]#

Bases: SpikesPlot

SpikesPlot with useful defaults for plotting adjoined rug plot.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, active_tools, align, apply_hard_bounds, autorange, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

holoviews.plotting.bokeh.chart.SpikesPlot: show_legend, spike_length, position, color_index

xaxis = param.ObjectSelector(allow_refs=False, default=’top-bare’, label=’Xaxis’, names={}, nested_refs=False, objects=[‘top’, ‘bottom’, ‘bare’, ‘top-bare’, ‘bottom-bare’, None], rx=<param.reactive.reactive_ops object at 0x170fb0d90>)

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(allow_refs=False, default=’right-bare’, label=’Yaxis’, names={}, nested_refs=False, objects=[‘left’, ‘right’, ‘bare’, ‘left-bare’, ‘right-bare’, None], rx=<param.reactive.reactive_ops object at 0x170fb2790>)

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’.

width = param.Integer(allow_refs=False, bounds=(0, None), default=50, inclusive_bounds=(True, True), label=’Width’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170fb2990>)

Width of plot

height = param.Integer(allow_refs=False, bounds=(0, None), default=50, inclusive_bounds=(True, True), label=’Height’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170fb2d50>)

Height of plot

border = param.Integer(allow_refs=False, default=5, inclusive_bounds=(True, True), label=’Border’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170fb2a90>)

Default borders on plot

selected = param.List(allow_None=True, allow_refs=False, bounds=(0, None), label=’Selected’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x170fb2410>)

The current selection as a list of integers corresponding to the selected items.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.SpikesPlot(element, plot=None, **params)[source]#

Bases: SpikesMixin, ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

show_legend = param.Boolean(allow_refs=False, default=True, label=’Show legend’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x171012a10>)

Whether to show legend for the plot.

spike_length = param.Number(allow_refs=False, default=0.5, inclusive_bounds=(True, True), label=’Spike length’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x171018610>)

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

position = param.Number(allow_refs=False, default=0.0, inclusive_bounds=(True, True), label=’Position’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x171018cd0>)

The position of the lower end of each spike.

color_index = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘int’>), label=’Color index’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x171013e10>)

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

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.SpreadPlot(element, plot=None, **params)[source]#

Bases: ElementPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

padding = param.ClassSelector(allow_refs=False, class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=(0, 0.1), label=’Padding’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x171088bd0>)

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.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.chart.VectorFieldPlot(element, plot=None, **params)[source]#

Bases: ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

padding = param.ClassSelector(allow_refs=False, class_=(<class ‘int’>, <class ‘float’>, <class ‘tuple’>), default=0.05, label=’Padding’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x171108f90>)

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(allow_refs=False, default=True, label=’Arrow heads’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x17110a650>)

Whether or not to draw arrow heads.

magnitude = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘holoviews.util.transform.dim’>), label=’Magnitude’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x171108ed0>)

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.

pivot = param.ObjectSelector(allow_refs=False, default=’mid’, label=’Pivot’, names={}, nested_refs=False, objects=[‘mid’, ‘tip’, ‘tail’], rx=<param.reactive.reactive_ops object at 0x17110a950>)

The point around which the arrows should pivot valid options include ‘mid’, ‘tip’ and ‘tail’.

rescale_lengths = param.Boolean(allow_refs=False, default=True, label=’Rescale lengths’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x171108b90>)

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

color_index = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘int’>), label=’Color index’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x17110a6d0>)

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

size_index = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘int’>), label=’Size index’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x17110a7d0>)

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

normalize_lengths = param.Boolean(allow_refs=False, default=True, label=’Normalize lengths’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x17110a310>)

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

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.


element Module#

class holoviews.plotting.bokeh.element.AnnotationPlot[source]#

Bases: object

Mix-in plotting subclass for AnnotationPlots which do not have a legend.

class holoviews.plotting.bokeh.element.ColorbarPlot(element, plot=None, **params)[source]#

Bases: ElementPlot

ColorbarPlot provides methods to create colormappers and colorbar models which can be added to a glyph. Additionally it provides parameters to control the position and other styling options of the colorbar. The default colorbar_position options are defined by the colorbar_specs, but may be overridden by the colorbar_opts.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

color_levels = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘int’>, <class ‘list’>, <class ‘range’>), label=’Color levels’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dc76b50>)

Number of discrete colors to use when colormapping or a set of color intervals defining the range of values to map each color to.

cformatter = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘bokeh.models.formatters.TickFormatter’>, <class ‘function’>), label=’Cformatter’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dcaad90>)

Formatter for ticks along the colorbar axis.

clabel = param.String(allow_None=True, allow_refs=False, label=’Clabel’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dca3310>)

An explicit override of the color bar label. If set, takes precedence over the title key in colorbar_opts.

clim = param.Tuple(allow_refs=False, default=(nan, nan), label=’Clim’, length=2, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dcab6d0>)

User-specified colorbar axis range limits for the plot, as a tuple (low,high). If specified, takes precedence over data and dimension ranges.

clim_percentile = param.ClassSelector(allow_refs=False, class_=(<class ‘int’>, <class ‘float’>, <class ‘bool’>), default=False, label=’Clim percentile’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dca3310>)

Percentile value to compute colorscale robust to outliers. If True, uses 2nd and 98th percentile; otherwise uses the specified numerical percentile value.

cnorm = param.ObjectSelector(allow_refs=False, default=’linear’, label=’Cnorm’, names={}, nested_refs=False, objects=[‘linear’, ‘log’, ‘eq_hist’], rx=<param.reactive.reactive_ops object at 0x16dc35a10>)

Color normalization to be applied during colormapping.

colorbar = param.Boolean(allow_refs=False, default=False, label=’Colorbar’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x1711cdd50>)

Whether to display a colorbar.

colorbar_position = param.ObjectSelector(allow_refs=False, default=’right’, label=’Colorbar position’, names={}, nested_refs=False, objects=[‘right’, ‘left’, ‘bottom’, ‘top’, ‘top_right’, ‘top_left’, ‘bottom_left’, ‘bottom_right’], rx=<param.reactive.reactive_ops object at 0x16dcaa090>)

Allows selecting between a number of predefined colorbar position options. The predefined options may be customized in the colorbar_specs class attribute.

colorbar_opts = param.Dict(allow_refs=False, class_=<class ‘dict’>, default={}, label=’Colorbar opts’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dca3d10>)

Allows setting specific styling options for the colorbar overriding the options defined in the colorbar_specs class attribute. Includes location, orientation, height, width, scale_alpha, title, title_props, margin, padding, background_fill_color and more.

clipping_colors = param.Dict(allow_refs=False, class_=<class ‘dict’>, default={}, label=’Clipping colors’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x1711581d0>)

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.

cticks = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘int’>, <class ‘list’>, <class ‘tuple’>, <class ‘numpy.ndarray’>, <class ‘bokeh.models.tickers.Ticker’>), label=’Cticks’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dca3d10>)

Ticks along colorbar-axis specified as an integer, explicit list of tick locations, or bokeh Ticker object. If set to None default bokeh ticking behavior is applied.

logz = param.Boolean(allow_refs=False, default=False, label=’Logz’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x1711581d0>)

Whether to apply log scaling to the z-axis.

rescale_discrete_levels = param.Boolean(allow_refs=False, default=True, label=’Rescale discrete levels’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x1711cdd50>)

If cnorm='eq_hist and there are only a few discrete values, then rescale_discrete_levels=True decreases the lower limit of the autoranged span so that the values are rendering towards the (more visible) top of the palette, thus avoiding washout of the lower values. Has no effect if cnorm!=`eq_hist.

symmetric = param.Boolean(allow_refs=False, default=False, label=’Symmetric’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dca3e90>)

Whether to make the colormap symmetric around zero.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.element.CompositeElementPlot(element, plot=None, **params)[source]#

Bases: ElementPlot

A CompositeElementPlot is an Element plot type that coordinates drawing of multiple glyphs.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.element.ElementPlot(element, plot=None, **params)[source]#

Bases: BokehPlot, GenericElementPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

fontsize = param.Parameter(allow_None=True, allow_refs=False, default={‘title’: ‘12pt’}, label=’Fontsize’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x15fe17190>)

Specifies various fontsizes of the displayed text. Finer control is available by supplying a dictionary where any unmentioned keys reverts to the default sizes, e.g: {‘ticks’: ‘20pt’, ‘title’: ‘15pt’, ‘ylabel’: ‘5px’, ‘xlabel’: ‘5px’}

xticks = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘int’>, <class ‘list’>, <class ‘tuple’>, <class ‘numpy.ndarray’>, <class ‘bokeh.models.tickers.Ticker’>), label=’Xticks’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104dc50>)

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.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘int’>, <class ‘list’>, <class ‘tuple’>, <class ‘numpy.ndarray’>, <class ‘bokeh.models.tickers.Ticker’>), label=’Yticks’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x160b30b90>)

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.

toolbar = param.ObjectSelector(allow_refs=False, default=’right’, label=’Toolbar’, names={}, nested_refs=False, objects=[‘above’, ‘below’, ‘left’, ‘right’, ‘disable’, None], rx=<param.reactive.reactive_ops object at 0x16104ca10>)

The toolbar location, must be one of ‘above’, ‘below’, ‘left’, ‘right’, None.

width = param.Integer(allow_None=True, allow_refs=False, bounds=(0, None), default=300, inclusive_bounds=(True, True), label=’Width’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104b990>)

The width of the component (in pixels). This can be either fixed or preferred width, depending on width sizing policy.

height = param.Integer(allow_None=True, allow_refs=False, bounds=(0, None), default=300, inclusive_bounds=(True, True), label=’Height’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104a650>)

The height of the component (in pixels). This can be either fixed or preferred height, depending on height sizing policy.

active_tools = param.List(allow_None=True, allow_refs=False, bounds=(0, None), label=’Active tools’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16db55810>)

Allows specifying which tools are active by default. Note that only one tool per gesture type can be active, e.g. both ‘pan’ and ‘box_zoom’ are drag tools, so if both are listed only the last one will be active. As a default ‘pan’ and ‘wheel_zoom’ will be used if the tools are enabled.

align = param.ObjectSelector(allow_refs=False, default=’start’, label=’Align’, names={}, nested_refs=False, objects=[‘start’, ‘center’, ‘end’], rx=<param.reactive.reactive_ops object at 0x16104ca10>)

Alignment (vertical or horizontal) of the plot in a layout.

apply_hard_bounds = param.Boolean(allow_refs=False, default=False, label=’Apply hard bounds’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16d952c50>)

If True, the navigable bounds of the plot will be set based on the more extreme of extents between the data or xlim/ylim ranges. If dim ranges are set, the hard bounds will be set to the dim ranges.

autorange = param.ObjectSelector(allow_refs=False, label=’Autorange’, names={}, nested_refs=False, objects=[‘x’, ‘y’, None], rx=<param.reactive.reactive_ops object at 0x16d6092d0>)

Whether to auto-range along either the x- or y-axis, i.e. when panning or zooming along the orthogonal axis it will ensure all the data along the selected axis remains visible.

border = param.Number(allow_refs=False, default=10, inclusive_bounds=(True, True), label=’Border’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x160b30b90>)

Minimum border around plot.

aspect = param.Parameter(allow_None=True, allow_refs=False, label=’Aspect’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16d963b10>)

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.

backend_opts = param.Dict(allow_refs=False, class_=<class ‘dict’>, default={}, label=’Backend opts’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16db57650>)

A dictionary of custom options to apply to the plot or subcomponents of the plot. The keys in the dictionary mirror attribute access on the underlying models stored in the plot’s handles, e.g. {‘colorbar.margin’: 10} will index the colorbar in the Plot.handles and then set the margin to 10.

data_aspect = param.Number(allow_None=True, allow_refs=False, inclusive_bounds=(True, True), label=’Data aspect’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104e090>)

Defines the aspect of the axis scaling, i.e. the ratio of y-unit to x-unit.

frame_width = param.Integer(allow_None=True, allow_refs=False, bounds=(0, None), inclusive_bounds=(True, True), label=’Frame width’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104a5d0>)

The width of the component (in pixels). This can be either fixed or preferred width, depending on width sizing policy.

frame_height = param.Integer(allow_None=True, allow_refs=False, bounds=(0, None), inclusive_bounds=(True, True), label=’Frame height’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104e090>)

The height of the component (in pixels). This can be either fixed or preferred height, depending on height sizing policy.

min_width = param.Integer(allow_None=True, allow_refs=False, bounds=(0, None), inclusive_bounds=(True, True), label=’Min width’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104b050>)

Minimal width of the component (in pixels) if width is adjustable.

min_height = param.Integer(allow_None=True, allow_refs=False, bounds=(0, None), inclusive_bounds=(True, True), label=’Min height’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104e090>)

Minimal height of the component (in pixels) if height is adjustable.

max_width = param.Integer(allow_None=True, allow_refs=False, bounds=(0, None), inclusive_bounds=(True, True), label=’Max width’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104bd50>)

Minimal width of the component (in pixels) if width is adjustable.

max_height = param.Integer(allow_None=True, allow_refs=False, bounds=(0, None), inclusive_bounds=(True, True), label=’Max height’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104e090>)

Minimal height of the component (in pixels) if height is adjustable.

margin = param.Parameter(allow_None=True, allow_refs=False, label=’Margin’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16d952c50>)

Allows to create additional space around the component. May be specified as a two-tuple of the form (vertical, horizontal) or a four-tuple (top, right, bottom, left).

multi_y = param.Boolean(allow_refs=False, default=False, label=’Multi y’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x15fe17190>)

Enables multiple axes (one per value dimension) in overlays and useful for creating twin-axis plots. When enabled, axis options are no longer propagated between the elements and the overlay container, allowing customization on a per-axis basis.

scalebar = param.Boolean(allow_refs=False, default=False, label=’Scalebar’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16d952c50>)

Whether to display a scalebar.

scalebar_range = param.Selector(allow_refs=False, default=’x’, label=’Scalebar range’, names={}, nested_refs=False, objects=[‘x’, ‘y’], rx=<param.reactive.reactive_ops object at 0x16068a150>)

Whether to have the scalebar on the x or y axis.

scalebar_unit = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘tuple’>), label=’Scalebar unit’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16068ba90>)

Unit of the scalebar. The order of how this will be done is by: 1. This value if it is set. 2. The elements kdim unit (if exist). 3. Meter If the value is a tuple, the first value will be the unit and the second will be the base unit. The scalebar_unit is only used if scalebar is True.

scalebar_location = param.Selector(allow_refs=False, label=’Scalebar location’, names={}, nested_refs=False, objects=[‘top_left’, ‘top_center’, ‘top_right’, ‘center_left’, ‘center_center’, ‘center_right’, ‘bottom_left’, ‘bottom_center’, ‘bottom_right’, ‘top’, ‘left’, ‘center’, ‘right’, ‘bottom’], rx=<param.reactive.reactive_ops object at 0x160b30b90>)

Location anchor for positioning scale bar. Default to ‘bottom_right’, except if subcoordinate_y is True then it will default to ‘right’. The scalebar_location is only used if scalebar is True.

scalebar_label = param.String(allow_refs=False, default=’@{value} @{unit}’, label=’Scalebar label’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16db57650>)

The label template. This can use special variables: * @{value} The current value. Optionally can provide a number formatter with e.g. @{value}{%.2f}. * @{unit} The unit of measure. The scalebar_label is only used if scalebar is True.

scalebar_tool = param.Boolean(allow_refs=False, default=True, label=’Scalebar tool’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x160745010>)

Whether to show scalebar tools in the toolbar, the tools are used to control scalebars visibility. The scalebar_tool is only used if scalebar is True.

scalebar_opts = param.Dict(allow_refs=False, class_=<class ‘dict’>, default={}, label=’Scalebar opts’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16db55810>)

Allows setting specific styling options for the scalebar. See https://docs.bokeh.org/en/latest/docs/reference/models/annotations.html#bokeh.models.ScaleBar for more information. The scalebar_opts is only used if scalebar is True.

subcoordinate_y = param.ClassSelector(allow_refs=False, class_=(<class ‘bool’>, <class ‘tuple’>), default=False, label=’Subcoordinate y’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16d6092d0>)

Enables sub-coordinate systems for this plot. Accepts also a numerical two-tuple that must be a range between 0 and 1, the plot will be rendered on this vertical range of the axis.

subcoordinate_scale = param.Number(allow_refs=False, bounds=(0, None), default=1, inclusive_bounds=(False, True), label=’Subcoordinate scale’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16104ca10>)

Scale factor for subcoordinate ranges to control the level of overlap.

responsive = param.ObjectSelector(allow_refs=False, default=False, label=’Responsive’, names={}, nested_refs=False, objects=[False, True, ‘width’, ‘height’], rx=<param.reactive.reactive_ops object at 0x16068bc50>)

gridstyle = param.Dict(allow_refs=False, class_=<class ‘dict’>, default={}, label=’Gridstyle’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16db55810>)

Allows customizing the grid style, e.g. grid_line_color defines the line color for both grids while xgrid_line_color exclusively customizes the x-axis grid lines.

labelled = param.List(allow_refs=False, bounds=(0, None), default=[‘x’, ‘y’], label=’Labelled’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x160887d10>)

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

lod = param.Dict(allow_refs=False, class_=<class ‘dict’>, default={‘factor’: 10, ‘interval’: 300, ‘threshold’: 2000, ‘timeout’: 500}, label=’Lod’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16db55810>)

Bokeh plots offer “Level of Detail” (LOD) capability to accommodate large (but not huge) amounts of data. The available options are: * factor : Decimation factor to use when applying decimation. * interval : Interval (in ms) downsampling will be enabled after an interactive event. * threshold : Number of samples before downsampling is enabled. * timeout : Timeout (in ms) for checking whether interactive tool events are still occurring.

show_frame = param.Boolean(allow_refs=False, default=True, label=’Show frame’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x15fe17190>)

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

shared_axes = param.Boolean(allow_refs=False, default=True, label=’Shared axes’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dc3fb50>)

Whether to invert the share axes across plots for linked panning and zooming.

default_tools = param.List(allow_refs=False, bounds=(0, None), default=[‘save’, ‘pan’, ‘wheel_zoom’, ‘box_zoom’, ‘reset’], label=’Default tools’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16d6092d0>)

A list of plugin tools to use on the plot.

tools = param.List(allow_refs=False, bounds=(0, None), default=[], label=’Tools’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x160b30b90>)

A list of plugin tools to use on the plot.

hover_tooltips = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘list’>, <class ‘str’>), label=’Hover tooltips’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16d6092d0>)

A list of dimensions to be displayed in the hover tooltip.

hover_formatters = param.Dict(allow_None=True, allow_refs=False, class_=<class ‘dict’>, label=’Hover formatters’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dc3fb50>)

A dict of formatting options for the hover tooltip.

hover_mode = param.ObjectSelector(allow_refs=False, default=’mouse’, label=’Hover mode’, names={}, nested_refs=False, objects=[‘mouse’, ‘vline’, ‘hline’], rx=<param.reactive.reactive_ops object at 0x16068bc50>)

The hover mode determines how the hover tool is activated.

xformatter = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘bokeh.models.formatters.TickFormatter’>, <class ‘function’>), label=’Xformatter’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dc3fb50>)

Formatter for ticks along the x-axis.

yformatter = param.ClassSelector(allow_None=True, allow_refs=False, class_=(<class ‘str’>, <class ‘bokeh.models.formatters.TickFormatter’>, <class ‘function’>), label=’Yformatter’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16068ba90>)

Formatter for ticks along the x-axis.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.element.LegendPlot(element, plot=None, **params)[source]#

Bases: ElementPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

legend_cols = param.Integer(allow_refs=False, bounds=(0, None), default=0, inclusive_bounds=(True, True), label=’Legend cols’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x1670c4ad0>)

Number of columns for legend.

legend_labels = param.Dict(allow_None=True, allow_refs=False, class_=<class ‘dict’>, label=’Legend labels’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x1661e5250>)

Label overrides.

legend_muted = param.Boolean(allow_refs=False, default=False, label=’Legend muted’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x1672188d0>)

Controls whether the legend entries are muted by default.

legend_offset = param.NumericTuple(allow_refs=False, default=(0, 0), label=’Legend offset’, length=2, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x1661e4a50>)

If legend is placed outside the axis, this determines the (width, height) offset in pixels from the original position.

legend_position = param.ObjectSelector(allow_refs=False, default=’top_right’, label=’Legend position’, names={}, nested_refs=False, objects=[‘top_right’, ‘top_left’, ‘bottom_left’, ‘bottom_right’, ‘right’, ‘left’, ‘top’, ‘bottom’], rx=<param.reactive.reactive_ops object at 0x1661e4650>)

Allows selecting between a number of predefined legend position options. The predefined options may be customized in the legend_specs class attribute.

legend_opts = param.Dict(allow_refs=False, class_=<class ‘dict’>, default={}, label=’Legend opts’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x1661e4a50>)

Allows setting specific styling options for the colorbar.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(element, ranges, range_type='combined', dimension=None, xdim=None, ydim=None, zdim=None, lims_as_soft_ranges=False, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.element.OverlayPlot(overlay, **kwargs)[source]#

Bases: GenericOverlayPlot, LegendPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.LegendPlot: legend_cols, legend_labels, legend_muted, legend_offset, legend_position, legend_opts

holoviews.plotting.plot.GenericOverlayPlot: show_legend, batched, legend_limit, style_grouping

tabs = param.Boolean(allow_refs=False, default=False, label=’Tabs’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16d1b5b50>)

Whether to display overlaid plots in separate panes

multiple_legends = param.Boolean(allow_refs=False, default=False, label=’Multiple legends’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x16dda8bd0>)

Whether to split the legend for subplots into multiple legends.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

get_extents(overlay, ranges, range_type='combined', dimension=None, **kwargs)[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.

If lims_as_soft_ranges is set to True, the xlim and ylim will be treated as soft ranges instead of the default case as hard ranges while computing the extents. This is used e.g. when apply_hard_bounds is True and xlim/ylim is set, in which case we limit the initial viewable range to xlim/ylim, but allow navigation up to the abs max between the data range and xlim/ylim.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None)[source]#

Initialize the matplotlib figure.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.


geometry Module#

class holoviews.plotting.bokeh.geometry.RectanglesPlot(element, plot=None, **params)[source]#

Bases: GeomMixin, LegendPlot, ColorbarPlot

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

holoviews.plotting.bokeh.element.LegendPlot: legend_cols, legend_labels, legend_muted, legend_offset, legend_position, legend_opts

selected = param.List(allow_None=True, allow_refs=False, bounds=(0, None), label=’Selected’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x17793a610>)

The current selection as a list of integers corresponding to the selected items.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

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

Use first two key dimensions to set names, and all four to set the data range.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.

Returns potential Link or Stream sources.

matches(spec)[source]#

Matches a specification against the current Plot.

model_changed(model)[source]#

Determines if the bokeh model was just changed on the frontend. Useful to suppress boomeranging events, e.g. when the frontend just sent an update to the x_range this should not trigger an update on the backend.

push()[source]#

Pushes plot updates to the frontend.

refresh(**kwargs)[source]#

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

set_root(root)[source]#

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.

sync_sources()[source]#

Syncs data sources between Elements, which draw data from the same object.

traverse(fn=None, specs=None, full_breadth=True)[source]#

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.

update_frame(*args, **kwargs)[source]#

Set the plot(s) to the given frame number. Operates by manipulating the matplotlib objects held in the self._handles dictionary.

If n is greater than the number of available frames, update using the last available frame.

class holoviews.plotting.bokeh.geometry.SegmentPlot(element, plot=None, **params)[source]#

Bases: GeomMixin, ColorbarPlot

Segments are lines in 2D space where each two each dimensions specify a (x, y) node of the line.

Parameters inherited from:

holoviews.plotting.plot.DimensionedPlot: fontscale, show_title, normalize, projection

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

holoviews.plotting.bokeh.plot.BokehPlot: title, shared_datasource, title_format

holoviews.plotting.bokeh.element.ElementPlot: fontsize, xticks, yticks, toolbar, width, height, active_tools, align, apply_hard_bounds, autorange, border, aspect, backend_opts, data_aspect, frame_width, frame_height, min_width, min_height, max_width, max_height, margin, multi_y, scalebar, scalebar_range, scalebar_unit, scalebar_location, scalebar_label, scalebar_tool, scalebar_opts, subcoordinate_y, subcoordinate_scale, responsive, gridstyle, labelled, lod, show_frame, shared_axes, default_tools, tools, hover_tooltips, hover_formatters, hover_mode, xformatter, yformatter

holoviews.plotting.bokeh.element.ColorbarPlot: color_levels, cformatter, clabel, clim, clim_percentile, cnorm, colorbar, colorbar_position, colorbar_opts, clipping_colors, cticks, logz, rescale_discrete_levels, symmetric

selected = param.List(allow_None=True, allow_refs=False, bounds=(0, None), label=’Selected’, nested_refs=False, rx=<param.reactive.reactive_ops object at 0x17778be50>)

The current selection as a list of integers corresponding to the selected items.

cleanup()[source]#

Cleans up references to the plot after the plot has been deleted. Traverses through all plots cleaning up Callbacks and Stream subscribers.

compute_ranges(obj, key, ranges)[source]#

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.

property current_handles#

Should return a list of plot objects that have changed and should be updated.

property framewise#

Property to determine whether the current frame should have framewise normalization enabled. Required for bokeh plotting classes to determine whether to send updated ranges for each frame.

get_aspect(xspan, yspan)[source]#

Computes the aspect ratio of the plot

get_data(element, ranges, style)[source]#

Returns the data from an element in the appropriate format for initializing or updating a ColumnDataSource and a dictionary which maps the expected keywords arguments of a glyph to the column in the datasource.

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

Use first two key dimensions to set names, and all four to set the data range.

get_padding(obj, extents)[source]#

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

get_zorder(overlay, key, el)[source]#

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

initialize_plot(ranges=None, plot=None, plots=None, source=None)[source]#

Initializes a new plot object with the last available frame.