Description Usage Arguments Value Author(s) Examples
Distance measures (between constructs or elements). Various distance measures between elements or constructs are calculated.
1 2 |
x |
|
along |
Whether to calculate distance for 1 = constructs (default) or for 2= elements. |
dmethod |
The distance measure to be used. This must be one of
"euclidean", "maximum", "manhattan", "canberra", "binary"
or "minkowski". Any unambiguous substring can be given.
For additional information on the different types type
|
p |
The power of the Minkowski distance, in case |
trim |
The number of characters a construct is trimmed to (default is
|
index |
Whether to print the number of the construct
(default is |
col.index |
Logical. Whether to add an extra index column so the
column names are indexes instead of construct names. This option
renders a neater output as long construct names will stretch
the output (default is |
digits |
Numeric. Number of digits to round to (default is
|
output |
The type of output printed to the console. |
upper |
Whether to display upper triangle of correlation matrix only
(default is |
... |
Additional parameters to be passed to function |
matrix
object.
Mark Heckmann
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | ## Not run:
# between constructs
distance(bell2010, along=1)
# between elements
distance(bell2010, along=2)
# several distance methods
distance(bell2010, dm="man") # manhattan distance
distance(bell2010, dm="mink", p=3) # minkowski metric to the power of 3
# to save the results without printing to the console
d <- distance(bell2010, out=0, trim=7)
d
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.