generateTimeShift: Generated time-shifted versions of a Wave-like object

View source: R/generateTimeShift.R

generateTimeShiftR Documentation

Generated time-shifted versions of a Wave-like object

Description

Given a Wave-like object (or list of Wave-like objects), this function generates time-shifted versions of the object. The time-shifted versions are generated by adding a constant amount of time to the start or end of the object. This is achieved by either inserting silence and truncating the object to the original length, or by rotating the audio within the object.

Usage

generateTimeShift(
  wave,
  type = "silent",
  amount = c(1, 2),
  where = "start",
  output = "list"
)

Arguments

wave

A Wave-like object or list of Wave-like objects.

type

The type of time-shift to apply. Either "silent" or "rotate".

amount

Vector of amount of time to shift by (seconds).

where

Where to insert silence if type is "silent".

output

Return a list.

Value

A Wave-like object or list of Wave-like objects.


sonicscrewdriver documentation built on May 29, 2024, 3:39 a.m.