Liking cljdoc? Tell your friends :D

Clojure only.

- bin-histogram-plot
- by
- calculate
- complement
- count
- count-binned
- count-unique
- defstatfn
- dependence
- gaussian
- histogram
- histogram-plot
- intersect
- intersection-name
- intersections
- linreg
- list
- make-set-function-name
- map-of
- map-with-key
- map-with-value
- max
- mean
- min
- pearson
- prepare-map
- prod
- ratio
- scatter-plot
- set
- sets
- statfn
- stats
- sum
- union
- union-name
- unions
- vector-space
- xget

`(by extractor field-name sfunc1 & sfuncs)`

Allows passing whole records to a stats function within a call to stats. Similar to map-with-key and map-with-value, but without creating a map.

Allows passing whole records to a stats function within a call to stats. Similar to map-with-key and map-with-value, but without creating a map.

`(complement f__6599__auto__ key & [complement-key])`

Add the complement of the subset named by key. If complement-key is provided that will be used as the name of the complement; otherwise "not-" will be prefixed to key.

Add the complement of the subset named by key. If complement-key is provided that will be used as the name of the complement; otherwise "not-" will be prefixed to key.

`(defstatfn fn-name monoidfn & {:keys [requires name doc]})`

Define a function for computing statistics suitable for passing as an argument to stats. Same as statfn, except that def is used to create a var holding the function, and there is an additional :doc optional argument for supplying a docstring.

Define a function for computing statistics suitable for passing as an argument to stats. Same as statfn, except that def is used to create a var holding the function, and there is an additional :doc optional argument for supplying a docstring.

`(intersect f__6599__auto__ key1 & keys)`

Add the intersection of two or more subsets, named by the key arguments, to the set given by the first argument. The resulting intersection will be named :Sx-and-y-and-...-and-zZ, where x, y, ... z are the names of the argument sets.

Add the intersection of two or more subsets, named by the key arguments, to the set given by the first argument. The resulting intersection will be named :Sx-and-y-and-...-and-zZ, where x, y, ... z are the names of the argument sets.

`(intersections s & keyseqs)`

Created nested intersections of the set, using the cross-products of pairs of the provided keys, starting with the innermost:

(intersections s :foo [:bar :baz] [[:quux :frob] :spam])

creates the following subsets, in this order:

Sbar-and-quux-and-frobZ Sbar-and-spamZ Sbaz-and-quux-and-frobZ Sbaz-and-spamZ Sfoo-and-bar-and-quux-and-frobZ Sfoo-and-bar-and-spamZ Sfoo-and-baz-and-quux-and-frobZ Sfoo-and-baz-and-spamZ

Created nested intersections of the set, using the cross-products of pairs of the provided keys, starting with the innermost: (intersections s :foo [:bar :baz] [[:quux :frob] :spam]) creates the following subsets, in this order: Sbar-and-quux-and-frobZ Sbar-and-spamZ Sbaz-and-quux-and-frobZ Sbaz-and-spamZ Sfoo-and-bar-and-quux-and-frobZ Sfoo-and-bar-and-spamZ Sfoo-and-baz-and-quux-and-frobZ Sfoo-and-baz-and-spamZ

`(make-set-function-name logical-operation-name keys)`

(make-set-function-name "and" [:a :b :c]) -> :Sa-and-b-and-cZ

(make-set-function-name "and" [:a :b :c]) -> :Sa-and-b-and-cZ

`(map-of type extractor field-name sfunc1 & sfuncs)`

Add a map named field-name to the result map. With type :key, as map-with-key; with type :value, as map-with-value.

Add a map named field-name to the result map. With type :key, as map-with-key; with type :value, as map-with-value.

`(map-with-key key-extractor field-name value-sfunc1 & value-sfuncs)`

Add a map named field-name to the result map. The keys for the map are computed using key-extractor. The values are drawn from the extractor passed to the enclosing stats call, and the remaining arguments are, as in stats, at least one function for computing statistics.

The function for computing the key receives the whole record the statistics are calculated for.

Example: If records have the structure

{:type [keyword], :balance [number]}

Then

(stats :balance mean (map-with-key :type :type->balance mean))

Computes the mean of all balances, and a map keyed by type whose values contain the means of balances for that type:

{:mean 40, :type->balance {:foo {:mean 20}, :bar {:mean 56}}}

Add a map named field-name to the result map. The keys for the map are computed using key-extractor. The values are drawn from the extractor passed to the enclosing stats call, and the remaining arguments are, as in stats, at least one function for computing statistics. The function for computing the key receives the whole record the statistics are calculated for. Example: If records have the structure {:type [keyword], :balance [number]} Then (stats :balance mean (map-with-key :type :type->balance mean)) Computes the mean of all balances, and a map keyed by type whose values contain the means of balances for that type: {:mean 40, :type->balance {:foo {:mean 20}, :bar {:mean 56}}}

```
(map-with-value value-extractor
field-name
value-sfunc1
&
value-sfuncs)
```

Add a map named field-name to the result map. The values for the map are computed using value-extractor. The keys are drawn from the extractor passed to the enclosing stats call, and the remaining arguments are, as in stats, at least one function for computing statistics.

The function for computing the value receives the whole record the statistics are calculated for.

Example: if records have the strucutre

{:type [keyword], :balance [number]}

Then

(stats :type count-binned (map-with-value :balance :type->balance mean))

Computes the number of records per type, and the mean of the balances per type:

{:count-binned {:foo 20, :bar 13}, :type->balance {:foo {:mean 20}, :bar {:mean 56}}}

Add a map named field-name to the result map. The values for the map are computed using value-extractor. The keys are drawn from the extractor passed to the enclosing stats call, and the remaining arguments are, as in stats, at least one function for computing statistics. The function for computing the value receives the whole record the statistics are calculated for. Example: if records have the strucutre {:type [keyword], :balance [number]} Then (stats :type count-binned (map-with-value :balance :type->balance mean)) Computes the number of records per type, and the mean of the balances per type: {:count-binned {:foo 20, :bar 13}, :type->balance {:foo {:mean 20}, :bar {:mean 56}}}

`(sets)`

`(sets pred-map)`

Describe subsets for which to calculate statistics.

The argument, if given, should be a map whose keys are subset names and whose values are predicates members of the subset should satisfy. An additional set, with the key :all and containing everything, will also be calculated.

If no argument is given, only the :all set will be calculated.

Describe subsets for which to calculate statistics. The argument, if given, should be a map whose keys are subset names and whose values are predicates members of the subset should satisfy. An additional set, with the key :all and containing everything, will also be calculated. If no argument is given, only the :all set will be calculated.

`(statfn fn-name monoidfn & {:keys [requires name]})`

Create a function for computing statistics suitable for passing as an argument to stats. "monoidfn" should be the underlying function that combines values. The computed value will be inserted in the result map with the same name as fn-name or, if it is provided, the value of the :name optional argument. The :requires optional argument should contain the names of the functions that monoidfn expects already to have run.

Functions that are more than just simple wrappers will probably not be able to use this macro: see e.g. ratio or map-{with-key,with-value,of}.

Create a function for computing statistics suitable for passing as an argument to stats. "monoidfn" should be the underlying function that combines values. The computed value will be inserted in the result map with the same name as fn-name or, if it is provided, the value of the :name optional argument. The :requires optional argument should contain the names of the functions that monoidfn expects already to have run. Functions that are more than just simple wrappers will probably not be able to use this macro: see e.g. ratio or map-{with-key,with-value,of}.

`(stats extractor stat-func1 & stats-funcs)`

Create a function for calculating groups of statistics.

Arguments are an extractor function and at least one statistical function.

The return value is a function of one argument. The result of calling the extractor function on this argument is then passed to the statistical functions.

For instance, (stats :x sum count max) will return a function that expects a map with an :x key and tallies the sum, count, and max the :x values:

(m/value ((stats :x sum count max) {:x 1})) {:sum 1 :count 1 :max 1}

It is not in general necessary to call the return value of this function directly.

Create a function for calculating groups of statistics. Arguments are an extractor function and at least one statistical function. The return value is a function of one argument. The result of calling the extractor function on this argument is then passed to the statistical functions. For instance, (stats :x sum count max) will return a function that expects a map with an :x key and tallies the sum, count, and max the :x values: > (m/value ((stats :x sum count max) {:x 1})) {:sum 1 :count 1 :max 1} It is not in general necessary to call the return value of this function directly.

`(union f__6599__auto__ key1 & keys)`

Add the union of two or more subsets, named by the key arguments, to the set given by the first argument. The resulting union will be named :Sx-or-y-or-...-or-zZ, where x, y, ... z are the names of the argument sets.

Add the union of two or more subsets, named by the key arguments, to the set given by the first argument. The resulting union will be named :Sx-or-y-or-...-or-zZ, where x, y, ... z are the names of the argument sets.

`(unions s & keyseqs)`

Created nested unions of the set, using the cross-products of pairs of the provided keys, starting with the innermost:

(unions s :foo [:bar :baz] [[:quux :frob] :spam])

creates the following subsets, in this order:

Sbar-or-quux-or-frobZ Sbar-or-spamZ Sbaz-or-quux-or-frobZ Sbaz-or-spamZ Sfoo-or-bar-or-quux-or-frobZ Sfoo-or-bar-or-spamZ Sfoo-or-baz-or-quux-or-frobZ Sfoo-or-baz-or-spamZ

Created nested unions of the set, using the cross-products of pairs of the provided keys, starting with the innermost: (unions s :foo [:bar :baz] [[:quux :frob] :spam]) creates the following subsets, in this order: Sbar-or-quux-or-frobZ Sbar-or-spamZ Sbaz-or-quux-or-frobZ Sbaz-or-spamZ Sfoo-or-bar-or-quux-or-frobZ Sfoo-or-bar-or-spamZ Sfoo-or-baz-or-quux-or-frobZ Sfoo-or-baz-or-spamZ

`(xget data sets & ks)`

Enables fetching of a value across multiple sets.

Enables fetching of a value across multiple sets.

**cljdoc** is a website building & hosting documentation for Clojure/Script libraries