Autompg violins

Most examples work across multiple plotting backends, this example is also available for:

In [1]:
import numpy as np
import holoviews as hv

from  bokeh.sampledata.autompg import autompg
hv.extension('matplotlib')
%output size=300 fig='svg'

Declaring data

In [2]:
violin = hv.Violin(autompg, ('yr', 'Year'), ('mpg', 'Miles per Gallon')).redim.range(mpg=(8, 45))

Plot

In [3]:
%%opts Violin [aspect=1.5] (facecolors=hv.Cycle('tab20'))
violin
Out[3]:

Download this notebook from GitHub (right-click to download).