apoc.agg

Qualified Name Type

apoc.agg.first(value Any) - returns the first value from the given collection.

Function

apoc.agg.graph(path Any) - returns all distinct nodes and relationships collected into a map with the keys nodes and relationships.

Function

apoc.agg.last(value Any) - returns the last value from the given collection.

Function

apoc.agg.maxItems(items Any, value Any, groupLimit Integer) - returns a map {items:[], value:n} where the value key is the maximum value present, and items represent all items with the same value. The size of the list of items can be limited to a given max size.

Function

apoc.agg.median(value Any) - returns the mathematical median for all non-null numeric values.

Function

apoc.agg.minItems(items Any, value Any, groupLimit Integer) - returns a map {items:[], value:n} where the value key is the minimum value present, and items represent all items with the same value. The size of the list of items can be limited to a given max size.

Function

apoc.agg.nth(value Any, offset Integer) - returns the nth value in the given collection (to fetch the last item of an unknown length collection, -1 can be used).

Function

apoc.agg.percentiles(value Number, percentiles [Float]) - returns the given percentiles over the range of numerical values in the given collection.

Function

apoc.agg.product(value Number) - returns the product of all non-null numerical values in the collection.

Function

apoc.agg.slice(value Any, from Integer, to Integer) - returns subset of non-null values from the given collection (the collection is considered to be zero-indexed). To specify the range from start until the end of the collection, the length should be set to -1.

Function

apoc.agg.statistics(value Number, percentiles [Float]) - returns the following statistics on the numerical values in the given collection: percentiles, min, minNonZero, max, total, mean, stdev.

Function