Registry / data / holoviews

holoviews

JSON →
library1.23.2pypypi✓ verified 22d ago

HoloViews is a high-level, declarative plotting API for the PyData ecosystem, providing a concise way to build complex, interactive visualizations. It works seamlessly with data structures from libraries like NumPy, Pandas, Xarray, Dask, and Narwhals, and can render plots using Bokeh, Matplotlib, or Plotly backends. The library maintains an active development pace with frequent patch and minor releases, typically every few weeks or months, ensuring broad compatibility and continuous feature enhancements.

pip install holoviews
INSTALL
IMPORT
SIG · HOLOVIEWS
H
holoviews
datapythonv1.23.2
Install
15.4s avg
Import
1070ms
Disk
388MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.23.2 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.915 runs
installs and imports cleanly · install 0.0s · import 1.093s · 390.2MB
glibc
py 3.103.915 runs
installs and imports cleanly · install 15.4s · import 1.047s · 380MB
388MB installed
● package 388MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

holoviews
import holoviews as hv

This quickstart demonstrates how to initialize HoloViews with a backend (Bokeh in this case) and create a simple `Curve` plot from NumPy data. The `hv.extension()` call is crucial for setting up the plotting backend in environments like Jupyter notebooks.

import holoviews as hv import numpy as np hv.extension('bokeh') # Create some sample data xs = np.linspace(0, 2 * np.pi, 100) ys = np.sin(xs) # Create a Curve Element curve = hv.Curve((xs, ys), 'x', 'y', label='Sine Wave') # Display the plot (in a Jupyter environment) curve
Debug
Known issues
gotchaAlways call `hv.extension()` with your desired backend (e.g., 'bokeh', 'matplotlib', 'plotly') at the start of your notebook or script to initialize the plotting system. Without it, plots will not render.
fix
Add `hv.extension('bokeh')` (or your chosen backend) after `import holoviews as hv`.
affects: All versions
gotchaHoloViews requires at least one plotting backend library (e.g., Bokeh, Matplotlib, Plotly) to be installed to render plots. Installing `holoviews` alone is often not enough.
fix
Install HoloViews with a backend using `pip install holoviews[bokeh]` or `pip install holoviews bokeh`.
affects: All versions
breakingHoloViews v1.21.0 and newer require Python 3.10 or later. Older Python versions are no longer supported.
fix
Upgrade your Python environment to 3.10 or newer. If you must use an older Python, pin HoloViews to a version less than 1.21.0 (e.g., `holoviews<1.21`).
affects: >=1.21.0
gotchaFor optimal performance with very large datasets, consider using HoloViews with `datashader`. Datashader can efficiently render millions or billions of points into a fixed-size raster image, preventing browser slowdowns.
fix
Install `datashader` (`pip install datashader`) and apply it using `hv.extension('bokeh', enable_mathjax=True)` or explicitly `.opts(tools=['hover'], data_aspect=1).hist().redim.range(y=(None,None))`.
affects: All versions, especially with large datasets
compatibilityHoloViews versions prior to 1.22.1 may have compatibility issues with Pandas 3.0. While efforts are made for forward compatibility, using an older HoloViews with a newer Pandas might lead to unexpected behavior.
fix
Upgrade HoloViews to 1.22.1 or newer if using Pandas 3.0+. If you need to stay on an older HoloViews, ensure your Pandas version is compatible (e.g., Pandas 2.x).
affects: <1.22.1
Errors
Common errors & fixes
ImportError: None of the backends could be imported
This error occurs when HoloViews cannot find or import any of its supported plotting backends (like Bokeh or Matplotlib), often due to missing installations, incompatible versions, or the backend not being initialized via `hv.extension()`.
fix
Ensure all recommended dependencies are installed with `pip install "holoviews[all]"` or `conda install -c pyviz holoviews bokeh matplotlib`. Then, explicitly load the desired backend at the start of your script or notebook, e.g., `import holoviews as hv; hv.extension('bokeh')`.
AttributeError: type object 'opts' has no attribute 'Curve'
This usually indicates that the `.opts` API is being used incorrectly, either by calling it directly on the `holoviews` module (`hv.opts`) when it's expected on an element, or due to an outdated HoloViews version with different API conventions for setting options.
fix
Update HoloViews to the latest version (`pip install -U holoviews` or `conda update holoviews`). Ensure you are either importing `opts` specifically as `from holoviews import opts` and using it as `opts.Curve(...)`, or applying `.opts()` directly to a HoloViews element, e.g., `my_curve.opts(width=400)`.
holoviews plot not showing
Plots might not display due to missing or incorrectly configured plotting backends, failure to call `hv.extension()` to activate a backend, or running HoloViews code in environments (like scripts or certain IDEs) that require explicit rendering commands to output the visualization.
fix
Verify that all necessary plotting backends (e.g., Bokeh, Matplotlib) are installed. Explicitly activate a backend at the beginning of your code using `hv.extension('bokeh')` or `hv.extension('matplotlib')`. If running outside a Jupyter environment, use `hv.render(my_plot)` to get the backend-specific plot object and then use the backend's `show()` or `save()` function (e.g., `from bokeh.plotting import show; show(hv.render(my_plot))`).
TypeError: __init__() takes 2 positional arguments but 4 were given
This error typically occurs when creating HoloViews elements like `hv.Dataset` where key dimensions (`kdims`) and value dimensions (`vdims`) are mistakenly passed as positional arguments instead of keyword arguments.
fix
Always pass `kdims` and `vdims` as keyword arguments when initializing HoloViews data elements. For example, instead of `hv.Dataset(data, ['x', 'y'], ['z'])`, use `hv.Dataset(data, kdims=['x', 'y'], vdims=['z'])`.
ModuleNotFoundError: No module named 'holoviews'
The HoloViews library has not been installed in the Python environment, or the environment is not active.
fix
Install HoloViews using pip or conda: `pip install holoviews` or `conda install holoviews`.
Upgrade
Version history
1.23.2latest on PyPI · released Aug 24, 2026
Audit
Dependencies
bokehoptionalPopular interactive plotting backend for HoloViews.
matplotliboptionalCommon static plotting backend for HoloViews.
plotlyoptionalInteractive plotting backend for HoloViews.
pandasoptionalPrimary data handling library.
xarrayoptionalFor N-dimensional labeled arrays and datasets.
daskoptionalFor parallel computing with large datasets.
narwhalsoptionalFor broader DataFrame compatibility, including Polars and DuckDB.
Agent activity
11 hits · last 30 days
node
10
Resources
holoviews — pip install holoviews · libregistry