Find nearest neighbors

Normalizes a character vector to a unit vector

1 | ```
normalize(x)
``` |

`x` |
a numeric or integer vector |

The (euclidean) norm of a vector *x* is defined as

*||x|| = √{Σ(x^2)}*

To normalize a vector to a unit vector *u* with *||u|| = 1*, the following equation is applied:

*x' = x/ ||x||*

The normalized vector as a numeric

Fritz Günther

1 2 3 4 5 6 7 8 9 |

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.