upsample: Upsample pitch contour

Description Usage Arguments Details Value Examples

View source: R/utilities_soundgen.R

Description

Internal soundgen function.

Usage

1
upsample(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

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

soundgen documentation built on Oct. 4, 2018, 9:04 a.m.