API Reference#

Warning

This is a provisional API that is under active development, incomplete, and subject to change before release.

Plot interface#

Plot

An interface for declaratively specifying statistical graphics.

Plot.add

Define a layer of the visualization in terms of mark and data transform(s).

Plot.facet

Produce subplots with conditional subsets of the data.

Plot.label

Add or modify labels for axes, legends, and subplots.

Plot.layout

Control the figure size and layout.

Plot.limit

Control the range of visible data.

Plot.on

Draw the plot into an existing Matplotlib object.

Plot.pair

Produce subplots with distinct x and/or y variables.

Plot.plot

Compile the plot spec and return the Plotter object.

Plot.save

Compile the plot and write it to a buffer or file on disk.

Plot.scale

Control mappings from data units to visual properties.

Plot.share

Control sharing of axis limits and ticks across subplots.

Plot.show

Compile and display the plot by hooking into pyplot.

Plot.theme

Control the default appearance of elements in the plot.

Marks#

Area

An interval mark that fills between baseline and data values.

Band

An interval mark that fills between minimum and maximum values.

Bar

An rectangular mark drawn between baseline and data values.

Bars

A faster Bar mark with defaults that are more suitable for histograms.

Dot

A mark suitable for dot plots or less-dense scatterplots.

Dots

A dot mark defined by strokes to better handle overplotting.

Line

A mark connecting data points with sorting along the orientation axis.

Lines

A faster but less-flexible mark for drawing many lines.

Path

A mark connecting data points in the order they appear.

Paths

A faster but less-flexible mark for drawing many paths.

Range

An oriented line mark drawn between min/max values.

Stats#

Agg

Aggregate data along the value axis using given method.

Est

Calculate a point estimate and error bar interval.

Hist

Bin observations, count them, and optionally normalize or cumulate.

PolyFit

Fit a polynomial of the given order and resample data onto predicted curve.

Moves#

Dodge

Displacement and narrowing of overlapping marks along orientation axis.

Jitter

Random displacement of marks along either or both axes to reduce overplotting.

Norm

Divisive scaling on the value axis after aggregating within groups.

Shift

Displacement of all marks with the same magnitude / direction.

Stack

Displacement of overlapping bar or area marks along the value axis.

Scales#

Nominal

A categorical scale without relative importance / magnitude.

Continuous

A numeric scale supporting norms and functional transforms.

Temporal

A scale for date/time data.