Usage
pitchtrack (sound, f0range = c(60,400), timestep = 2, fs = 22050, minacf = .5,
correction = TRUE, show = TRUE, windowlength = 50, addtospect = FALSE)
Arguments
sound
A numeric vector representing a waveform, or a 'sound' object created with the loadsound() or makesound() functions.
f0range
A numeric vector of length two where the first value corresponds to the minimum f0 Hz to be considered, and the second represents the maximum to be considered.
timestep
How far the analysis window will advance, in milliseconds. If this value is set to zero, the function is applied to the entire signal.
fs
The sampling frequency of the sound. If a 'sound' or 'ts' object is passed, this does not need to be specified.
minacf
Autocorrelation values below this are ignored.
correction
If TRUE, ACF values are corrected for lag value.
show
If TRUE, a plot displaying the pitch track is created.
windowlength
The length of the analysis window, in milliseconds. This should be approximately three-times longer than the wavelength of the lowest pitch. The default value is appropriate for a floor of 60 Hz.
addtospect
If TRUE, the pitch track is added to a spectrogram created with the spectrogram() function included in this package. The track is scaled up by a factor of 10 (e.g., 100 Hz will be plotted at 1000 Hz on the spectrogram) so that it will fit nicely in the ty