dyad {tabr} | R Documentation |
Construct a dyad
Description
Construct a dyad given one note, an interval, and a direction.
Usage
dyad(
notes,
interval,
reverse = FALSE,
octaves = c("tick", "integer"),
accidentals = c("flat", "sharp"),
key = NULL
)
Arguments
notes |
character, a noteworthy string, single notes only, no chords.
Number of timesteps must equal the length of |
interval |
integer or character vector; semitones or interval ID, respectively. See details. |
reverse |
logical, reverse the transposition direction. Useful when
|
octaves , accidentals , key |
See |
Details
The interval
may be specified by semitones of by common interval name
or abbreviation. See examples.
For a complete list of valid interval names and abbreviations see
mainIntervals()
.
key
enforces the use of sharps or flats. This function is based on
transpose()
.
notes
and interval
may be vectors, but must be equal length.
Recycling occurs only if one argument is scalar.
Value
character
See Also
Examples
dyad("a", 4)
x <- c("minor third", "m3", "augmented second", "A2")
dyad("a", x)
dyad("c'", x, reverse = TRUE)
x <- c("M3", "m3", "m3", "M3", "M3", "m3", "m3")
dyad(letters[c(3:7, 1, 2)], x)
x <- c("P1", "m3", "M3", "P4", "P5", "P8", "M9")
dyad("c", x)
dyad("c", x, reverse = TRUE)
dyad("d e", "m3")
[Package tabr version 0.5.0 Index]