import numpy as np import holoviews as hv from holoviews import opts hv.extension('matplotlib') hv.output(fig='svg', size=200) np.random.seed(44) hex_tiles = hv.HexTiles(np.random.randn(100000, 2)) hex_tiles.opts(colorbar=True) xs, ys = np.random.randn(2, 1000) hex_with_values = hv.HexTiles((xs, ys, xs*(ys/2.), (xs**2)*ys), vdims=['Values', 'Hover Values']) points = hv.Points(hex_with_values) (hex_with_values * points).opts( opts.HexTiles(aggregator=np.sum), opts.Points(s=3, color='black')) x, y = np.hstack([np.random.randn(2, 10000), np.random.randn(2, 10000)*0.8+2]) hex_two_distributions = hv.HexTiles((x, y)) bivariate = hv.Bivariate((x, y)) (hex_two_distributions * bivariate).opts( opts.Bivariate(linewidth=3, show_legend=False), opts.HexTiles(min_count=0))