upsampleGC: Upsample glottal cycles

View source: R/soundgen_utilities.R

upsampleGCR Documentation

Upsample glottal cycles

Description

Internal soundgen function.

Usage

upsampleGC(pitch_per_gc, samplingRate = 16000)

Arguments

pitch_per_gc

a vector of fundamental frequencies per glottal cycle

samplingRate

target sampling rate after upsampling, in Hz

Details

Upsamples a pitch contour to samplingRate through linear interpolation between successive glottal cycles.

Value

Returns a list of two vectors: pitch_upsampled (the upsampled version of the input) and gc_upsampled (new indices of glottal cycles on an upsampled scale)

Examples

soundgen:::upsampleGC(pitch_per_gc = c(100, 150, 130), samplingRate = 16000)

soundgen documentation built on Sept. 12, 2024, 6:29 a.m.