R package reference manual for gower 1.0.2, a C-based implementation of Gower's distance and similarity coefficient.
The gower package (version 1.0.2) provides a C-based implementation of Gower's distance (or similarity) coefficient between records, with core algorithms executed in parallel on systems supporting OpenMP. It is maintained by Mark van der Loo and distributed through CRAN.
The manual documents two functions: gower_dist, which computes Gower's distance pairwise between records in two data sets, and gower_topn, which finds the top-n matches in y for each record in x. Both accept optional column-pairing arguments, weights, an epsilon threshold, case handling and a thread count for parallelization.
| Version | 1.0.2 |
|---|---|
| License | GPL-3 |
| Implementation | C-based |
| Parallelization | OpenMP |
| Maintainer | Mark van der Loo |
It computes Gower's distance (or similarity) coefficient between records, and can also find the top-n matches between records.
Gower (1971) originally defined a similarity measure with values from 0 (completely dissimilar) to 1 (completely similar); the distance returned here equals 1 minus s.
For a dual-core machine, 2 threads are used; for any other machine, n-1 cores are used so the machine does not freeze during a big computation.
You can give no specification and use columns with matching names, use only the pair_y argument, or explicitly specify the columns to be matched using pair_x and pair_y.