gyptis.vega-templates
Helper functions that produce and manipulate vega.js plot declarations.
->Bar
(->Bar data)
Positional factory function for class gyptis.vega_templates.Bar.
->Choropleth
(->Choropleth data)
Positional factory function for class gyptis.vega_templates.Choropleth.
->DodgedBar
(->DodgedBar data)
Positional factory function for class gyptis.vega_templates.DodgedBar.
->Line
(->Line data)
Positional factory function for class gyptis.vega_templates.Line.
->Point
(->Point data)
Positional factory function for class gyptis.vega_templates.Point.
->StackedBar
(->StackedBar data)
Positional factory function for class gyptis.vega_templates.StackedBar.
->vg-data
(->vg-data data)(->vg-data data fields)
Converts objects like Date into data that vega.js understands.
->vg-data*
(->vg-data* data field)
assoc-hover
(assoc-hover vg hover-spec)
choropleth
(choropleth [datum & more :as data] geopath-transform fill)
dodged-bar
(dodged-bar [datum & more :as data] x y fill)
Returns a vega spec for plotting a dodged bar plot. Requires x and
y aesthetics. Optional aesthetics: fill
ensure-facet-keys
(ensure-facet-keys data facet_x facet_y)
facet
(facet inner-spec [datum & more :as data] facet_x facet_y)
Takes a vega spec and produces a vega spec with a facetted layout
based on the facet_x and facet_y fields.
FacetGrid
protocol
Facetting plots is to make many subplots. Also known as small multiples or trellis plots.
members
facet-grid
(facet-grid this spec facet-x facet-y {:keys [facet_x facet_y]})
guess-scale-type
(guess-scale-type data field)
Returns "linear" or "ordinal" or "time" or throws an exception.
line
(line [datum & more :as data] x y stroke)
map->Bar
(map->Bar m__6289__auto__)
Factory function for class gyptis.vega_templates.Bar, taking a map of keywords to field values.
map->Choropleth
(map->Choropleth m__6289__auto__)
Factory function for class gyptis.vega_templates.Choropleth, taking a map of keywords to field values.
map->DodgedBar
(map->DodgedBar m__6289__auto__)
Factory function for class gyptis.vega_templates.DodgedBar, taking a map of keywords to field values.
map->Line
(map->Line m__6289__auto__)
Factory function for class gyptis.vega_templates.Line, taking a map of keywords to field values.
map->Point
(map->Point m__6289__auto__)
Factory function for class gyptis.vega_templates.Point, taking a map of keywords to field values.
map->StackedBar
(map->StackedBar m__6289__auto__)
Factory function for class gyptis.vega_templates.StackedBar, taking a map of keywords to field values.
point
(point [datum & more :as data] x y fill size)
Returns a vega spec for drawing points. Each datum is required to
have the x and y keys, and optionally fill and size.
stacked-bar
(stacked-bar [datum & more :as data] x y fill)
Stacks bars on the `fill' field
suppress-axis-labels
(suppress-axis-labels axis)
VegaSpec
protocol
members
->vg-spec
(->vg-spec this opts)
Returns a clj hashmap of a vega plot specification.
vertical-x-labels
(vertical-x-labels spec)
Returns a vega.js spec with x-axis labels oriented vertically.