snip: Snip/Zoom

snipR Documentation

Snip/Zoom

Description

Select a subsection of a sound or spectrogram object.

Usage

snip  (object, show = TRUE)

Arguments

object

A 'sound' or 'spectrogram' object to be truncated.

show

If TRUE, the selected subsection is displayed, resulting in zoom functionality.

Details

The input object is plotted and the user must click on two points on the plot. If show = TRUE, this function allows the user to zoom in on a subsection of the object. If the output is assigned to a variable, a new object is created and returned that contains only the data in between the two designated points.

Value

A 'sound' or 'spectrogram' object which interacts with several functions included in this package.

Author(s)

Santiago Barreda <sbarreda@ucdavis.edu>

Examples

#data (sound)
## the example below is commented because examples cannot 
## require user interaction. simply uncomment the lines below
## and select two points on the plot. 
# clipped = snipsound (sound)
# spectrogram (clipped)
# spectralslice (clipped)

phonTools documentation built on Nov. 21, 2023, 1:07 a.m.

Related to snip in phonTools...