Core domain types and operations.
A domain is an immutable collection of benchmark runs indexed by coordinates. This namespace provides the foundational data structures used by criterium.domain.builder and criterium.domain.analysis.
Core domain types and operations. A domain is an immutable collection of benchmark runs indexed by coordinates. This namespace provides the foundational data structures used by criterium.domain.builder and criterium.domain.analysis.
(add-run domain coord data)Add a benchmark result to a domain with the given coordinates. Returns a new domain. If a run with the same coordinates already exists, it is replaced.
coord can be either a keyword label or a map of dimension keys to values. data is the full benchmark result from bench.
Add a benchmark result to a domain with the given coordinates. Returns a new domain. If a run with the same coordinates already exists, it is replaced. coord can be either a keyword label or a map of dimension keys to values. data is the full benchmark result from bench.
(axes domain)Infer dimension keys from all map coordinates in a domain. Returns a set of keys. Keyword coordinates contribute no keys.
Infer dimension keys from all map coordinates in a domain. Returns a set of keys. Keyword coordinates contribute no keys.
(coords domain)Return all coordinates from a domain as a vector. Preserves the order of runs.
Return all coordinates from a domain as a vector. Preserves the order of runs.
(domain & args)Create a domain from runs. Returns empty domain when called with no args.
Each run is a map with :coord (keyword or map) and :data (bench result).
Options (as final map argument):
Create a domain from runs. Returns empty domain when called with no args. Each run is a map with :coord (keyword or map) and :data (bench result). Options (as final map argument): - :impl-axis - Coordinate axis for implementations - :implementations - Vector of impl keys to include
(impl-axis domain)Returns the impl-axis key for a domain, or nil if not set. The impl-axis specifies which coordinate axis represents different implementations for comparison analysis.
Returns the impl-axis key for a domain, or nil if not set. The impl-axis specifies which coordinate axis represents different implementations for comparison analysis.
(implementations domain)Returns the implementation keys for a domain. Defaults to [:default] for domains without explicit implementations.
Returns the implementation keys for a domain. Defaults to [:default] for domains without explicit implementations.
(remove-run domain coord)Remove a run from a domain by coordinates. Returns a new domain. If no run with the given coordinates exists, returns the domain unchanged.
Remove a run from a domain by coordinates. Returns a new domain. If no run with the given coordinates exists, returns the domain unchanged.
(runs domain)(runs domain partial-coord)Return runs from a domain, optionally filtered by partial coordinate. For map coords, partial matching is supported (subset match).
Return runs from a domain, optionally filtered by partial coordinate. For map coords, partial matching is supported (subset match).
(select domain partial-coord)Filter domain to runs matching a partial coordinate. Returns a new domain. For map coords, partial matching is supported (subset match).
Filter domain to runs matching a partial coordinate. Returns a new domain. For map coords, partial matching is supported (subset match).
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |