stream.lineEnd()

stream.lineEnd() Indicates the end of a line or ring. Within a polygon, indicates the end of a ring. Unlike GeoJSON, the redundant closing coordinate of a ring is not indicated via point, and instead is implied via lineEnd within a polygon. Thus, the given polygon input: { "type": "Polygon", "coordinates": [ [[0, 0], [1, 0], [1, 1], [0, 1], [0, 0]] ] } Will produce the following series of method calls on the stream: stream.polygonStart(); stream.lineStart(); stream.point(0, 0); strea

stratify.parentId()

stratify.parentId([parentId]) If parentId is specified, sets the parent id accessor to the given function and returns this stratify operator. Otherwise, returns the current parent id accessor, which defaults to: function parentId(d) { return d.parentId; } The parent id accessor is invoked for each element in the input data passed to the stratify operator, being passed the current datum (d) and the current index (i). The returned string is then used to identify the node’s relationships in c

stratify.id()

stratify.id([id]) If id is specified, sets the id accessor to the given function and returns this stratify operator. Otherwise, returns the current id accessor, which defaults to: function id(d) { return d.id; } The id accessor is invoked for each element in the input data passed to the stratify operator, being passed the current datum (d) and the current index (i). The returned string is then used to identify the node’s relationships in conjunction with the parent id. For leaf nodes, the

stratify()

stratify(data) Generates a new hierarchy from the specified tabular data. Each node in the returned object has a shallow copy of the properties from the corresponding data object, excluding the following reserved properties: id, parentId, children.

stack.value()

stack.value([value]) If value is specified, sets the value accessor to the specified function or number and returns this stack generator. If value is not specified, returns the current value accessor, which defaults to: function value(d, key) { return d[key]; } Thus, by default the stack generator assumes that the input data is an array of objects, with each object exposing named properties with numeric values; see stack for an example.

stack.order()

stack.order([order]) If order is specified, sets the order accessor to the specified function or array and returns this stack generator. If order is not specified, returns the current order acccesor, which defaults to stackOrderNone; this uses the order given by the key accessor. See stack orders for the built-in orders. If order is a function, it is passed the generated series array and must return an array of numeric indexes representing the stack order. For example, the default order is d

stack.offset()

stack.offset([offset]) If offset is specified, sets the offset accessor to the specified function or array and returns this stack generator. If offset is not specified, returns the current offset acccesor, which defaults to stackOffsetNone; this uses a zero baseline. See stack offsets for the built-in offsets. If offset is a function, it is passed the generated series array and the order index array. The offset function is then responsible for updating the lower and upper values in the serie

stack.keys()

stack.keys([keys]) If keys is specified, sets the keys accessor to the specified function or array and returns this stack generator. If keys is not specified, returns the current keys accessor, which defaults to the empty array. A series (layer) is generated for each key. Keys are typically strings, but they may be arbitrary values. The series’ key is passed to the value accessor, along with each data point, to compute the point’s value.

stack()

stack(data[, arguments…]) Generates a stack for the given array of data, returning an array representing each series. Any additional arguments are arbitrary; they are simply propagated to accessors along with the this object. The series are determined by the keys accessor; each series i in the returned array corresponds to the ith key. Each series is an array of points, where each point j corresponds to the jth element in the input data. Lastly, each point is represented as an array [y0, y1]

squarify.ratio()

squarify.ratio(ratio) Specifies the desired aspect ratio of the generated rectangles. The ratio must be specified as a number greater than or equal to one. Note that the orientation of the generated rectangles (tall or wide) is not implied by the ratio; for example, a ratio of two will attempt to produce a mixture of rectangles whose width:height ratio is either 2:1 or 1:2. (However, you can approximately achieve this result by generating a square treemap at different dimensions, and then st