Using Brain to feed in an array of data with both positive and negative numbers; the output array will be in 0's and 1's and I believe Brain only allows inputs from 0 to 1. So how do I normalize an array of negative and positive numbers so it fits these requirements?
How do I normalize an array of positive and negative numbers so they are between 0 and 1?
machine learning;javascript
This is called unity-based normalization. If you have a vector $X$, you can obtain a normalized version of it, say $Z$, by doing:$$Z = \frac{X - \min(X)}{\max(X) - \min(X)}$$ 