newmana/chroma-elm/10.1.1

NOTE: the latest version is 18.2.1

Rerouted (retagged, verified). The tag now points at a different commit than when this version was published. The Lamdera package server serves a copy recovered from https://github.com/newmana/chroma-elm.

What we checked: Tag 10.1.1 now points at c09d06b75e39, not the published commit. Rebuilt with git archive from commit 51684c31ed38 of https://github.com/newmana/chroma-elm (zip prefix newmana-chroma-elm-51684c3/, America/Los_Angeles times): the zip is byte-identical to the one package.elm-lang.org recorded, SHA-1 c7cb31d365d767882e728ab60ac1a1d66f0fd85f.

The Lamdera compiler uses this copy and prints a one-line notice saying so. elm itself fails to download this version.

Details · package.elm-lang.org's zip: https://github.com/newmana/chroma-elm/zipball/10.1.1/

Chroma.Limits.CkMeans

A log linear implementation of CkMeans. It uses a divide-and-conquer algorithm to compute a row in the dynamic programming matrix in O(n lg n) time. The Simple Statistic's implementation was used to validate this implementation.

There is a better one (not implemented) using the SMAWK optimisation.

The limit function produces class breaks like the other implementations and binned puts all data values into their bins.

Definition

binned : Int -> Scale -> Nonempty (Array Float)

Return the values in Scale into the given number of bins. For example, 1 [3,3,3,4] -> 3 bins -> [[1], [3,3,3], [4]]

limit : Int -> Scale -> Nonempty Float

Create up to bins number of results using the given scale.

Helpers

converge : Int -> Int -> Int -> Float -> CkRest -> ( Float, Int )

TBD

defaultResult : Int -> Int -> CkResult

TBD

fillRestOfMatrix : Int -> Scale -> CkRest -> CkResult

TBD

firstLine : Int -> Scale -> CkRest

TBD

getMatrixIndexes : Int -> List Int

TBD

getValues : Int -> Int -> List ( Int, Int )

TBD