Liking cljdoc? Tell your friends :D

noon.utils.sequences

sequences transformation with the consideration of increasing complexity

sequences transformation with the consideration of increasing complexity
raw docstring

decimal->idxclj

(decimal->idx s d)

take a sequence and a number between 0 and 1, 0 being the first idx and 1 the last. also supports negative numbers to (-1 being the first idx and -0 the last) return the corresponding integer index.

take a sequence and a number between 0 and 1,
0 being the first idx and 1 the last.
also supports negative numbers to (-1 being the first idx and -0 the last)
return the corresponding integer index.
sourceraw docstring

default-split-sizesclj

(default-split-sizes s)

default available split sizes for the given sequence

default available split sizes for the given sequence
sourceraw docstring

factorsclj

(factors x)
source

grade-permutationsclj

(grade-permutations s n)
(grade-permutations s n split-sizes)
source

gradual-permutationsclj

(gradual-permutations s)
(gradual-permutations s split-sizes)

take a sequence s to permute, returns a grade->permutations map.

take a sequence s to permute,
returns a grade->permutations map.
sourceraw docstring

idx-permutationsclj

source

MAX_GRADEclj

source

memberclj

(member s x)

Find or pick an element within a sequence 's. available forms: (member s <integer>) normal nth like get (member s <negative-integer>) nth from the end of the list (member s <float-or-rational>) a non integer between -1 and 1, is picking a member relatively to the length of the list, forward if positive, backward if negative. (member s <[min max]>) picks a member randomly between the given idxs (every type of index allowed) (member s <:rand|:random>) picks a random member

Find or pick an element within a sequence 's.
available forms:
(member s <integer>) normal nth like get
(member s <negative-integer>) nth from the end of the list
(member s <float-or-rational>) a non integer between -1 and 1, is picking a member relatively to the length of the list, forward if positive, backward if negative.
(member s <[min max]>) picks a member randomly between the given idxs (every type of index allowed)
(member s <:rand|:random>) picks a random member
sourceraw docstring

mirror-idxclj

(mirror-idx s idx)
source

partitionsclj

(partitions x)
source

permutationclj

(permutation s)
(permutation s idx)
(permutation s idx {:keys [grade split-bounds split-sizes min-split max-split]})
source

permutation-gradesclj

(permutation-grades s)

return a seq of available permutation grades for the given seq

return a seq of available permutation grades for the given seq
sourceraw docstring

rotateclj

(rotate coll n)
source

rotationclj

(rotation s x)
source

rotationsclj

(rotations x)
source

seq-idxclj

(seq-idx s x)
source

seq-sectionclj

(seq-section s [from to])
source

shuffle-no-repclj

shuffle a sequence while avoiding to produce successive equal elements.

shuffle a sequence while avoiding to produce successive equal elements.
sourceraw docstring

simple-permutationsclj

(simple-permutations x)

lazy seq of permutations by increasing complexity

lazy seq of permutations
by increasing complexity
sourceraw docstring

simple-subseqsclj

(simple-subseqs x)
source

split-permutationsclj

source

splitsclj

(splits s n)
(splits s n sizes)

takes a seq 's and a number of splits 'n return all possible splits of 's of size 'n

takes a seq 's and a number of splits 'n
return all possible splits of 's of size 'n
sourceraw docstring

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

× close