vl_dist {musicMCT} | R Documentation |
How far apart are two scales?
Description
Using the chosen method
to measure distance, determines how far
apart two scales are in voice-leading space.
Usage
vl_dist(
set_1,
set_2,
method = c("taxicab", "euclidean", "chebyshev", "hamming"),
rounder = 10
)
Arguments
set_1 , set_2 |
Numeric vectors of pitch-classes in the sets. Must be of same length. |
method |
What distance metric should be used? Defaults to |
rounder |
Numeric (expected integer), defaults to |
Value
Numeric: distance between set_1
and set_2
Examples
c_major <- c(0, 4, 7)
a_minor_63 <- c(0, 4, 9)
f_minor_64 <- c(0, 5, 8)
vl_dist(c_major, a_minor_63)
vl_dist(c_major, f_minor_64)
vl_dist(c_major, a_minor_63, method="euclidean")
vl_dist(c_major, f_minor_64, method="euclidean")
[Package musicMCT version 0.2.0 Index]