Module: AreaLayer

Area layer renders a closed path. The mark type of this layer is ```area```. This layer can be used to create stacked or multi-series areas and vertical range area plots by using the encoding properties. To create this layer using layer configuration from canvas, ``` canvas.layers([{ mark: 'area', transform: { type: 'stack' // Produces a stacked area. } }]); ```
Source:

Methods

(static) defaultConfig() → {Object}

oation of line layer
Source:
Returns:
Default configuration of layer
Type
Object

calculateDomainFromData() → {Array}

Calculates the domain from data. It calls its parent class's method which is line layer to get the domain and overwrites the domain according to its need.
Source:
Returns:
Domain values
Type
Array

getDrawFn() → {function}

Returns the drawing method of this layer
Source:
Returns:
Draw method
Type
function

getPathStyle(color) → {Object}

Get the css styles need to be applied on the line path
Parameters:
Name Type Description
color string Color value
Source:
Returns:
Path styles
Type
Object

translatePoints(data, encoding, axes) → {Array}

Generates the x and y positions for each point
Parameters:
Name Type Description
data Array Data Array
encoding Object Visual Encodings of the layer
axes Object Contains the axis
Source:
Returns:
Array of points
Type
Array