Portability | portable |
---|---|

Stability | experimental |

Maintainer | gnn.github@gmail.com |

The GSOM algorithm works on numerical input vectors. These input vectors
are internally represented as lists of

s and this module contains
the functions working on these.
`Double`

- type Bounds = [(Double, Double)]
- type Input = [Double]
- type Inputs = [Input]
- bounds :: Inputs -> Bounds
- dimension :: Inputs -> Int
- normalize :: Bounds -> Inputs -> Inputs
- unnormalize :: Bounds -> Inputs -> Inputs
- distance :: Input -> Input -> Double
- (*.) :: Input -> Double -> Input
- (.*) :: Double -> Input -> Input
- (<+>) :: Input -> Input -> Input
- (<->) :: Input -> Input -> Input

# Documentation

type Bounds = [(Double, Double)]Source

The bounds of a list of inputs. Having the tuple `(a,b)`

at index `i`

in `bounds`

means that the value at index `i`

of each of the input vectors
from the inputs which where used to calculate `bounds`

is from the
intervall `[a,b]`

.

dimension :: Inputs -> IntSource

Calculating the dimension of a given set of inputs just means finding the length of the longest input vector.

normalize :: Bounds -> Inputs -> InputsSource

Normalizes input vectors.

takes the given list of input vectors `normalize`

inputs`inputs`

and
returns a list of input vectors where each component is in `[0,1]`

.
If you want to unnormalize the input vectors use

and
`bounds`

.
`unnormalize`

unnormalize :: Bounds -> Inputs -> InputsSource

Unnormalizes the given input vectors `inputs`

assuming that it's bounds
previously where `bounds`

.