David Meyer
2007-Jul-09 13:49 UTC
[R] [R-pkgs] New package "proxy" for distances and similiarities
Dear useRs, a new package for computing distance and similarity matrices made it to CRAN, and will propagate to the mirrors soon. It includes an enhanced version of "dist()" with support for more than 40 popular similarity and distance measures, both for auto- and cross-distances. Some important ones are implemented in C. The proximity measures are stored in a registry which can easily be queried and extended by users at run-time. For adding a new measure, the simplest way is to provide the distance measure as a small R function, the package code will do the loops on the C code level to create the proximity matrix. It is of course also possible to use more efficient C implementations---either for the distance measure alone, or the whole matrix computation. Input data is not restricted to matrices: provided the proximity measure can handle it, lists and data frames are also accepted. The formulas for binary proximities can conveniently be specified in the a/b/c/d/n format, where the number of concordant/discordant pairs is precomputed on the C code level. We are currently working on support for sparse data. This is also a "Call for Measures": if you feel that a particular similarity of distance measure is missing, please send the formula and a reference (or, ideally, the whole registry entry) to one of the package maintainers who will happily add it. David and Christian. _______________________________________________ R-packages mailing list R-packages at stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-packages
Maybe Matching Threads
- New package "proxy" for distances and similiarities
- Logistic Regression in R (SAS -like output)
- random forest -optimising mtry
- Interpreting the example given by Prof Frank Harrell in {Design} validate.cph
- Need help interpreting output from rcorrp.cens with Cox regression