View source: R/decimateWavFiles.R
decimateWavFiles | R Documentation |
Decimate a folder of .wav files or a single .wav file to a new sample rate.
decimateWavFiles(inDir, outDir, newSr, progress = TRUE)
inDir |
directory of wave files to decimate. Can also be a single .wav file. |
outDir |
directory to write wave files to |
newSr |
sample rate to decimate the files to |
progress |
logical flag to show progress bar |
This code is based on R code written by Jay Barlow.
Invisibly returns the names of all files that were successfully decimated
Taiki Sakai taiki.sakai@noaa.gov
# one 20kHz wav file is included in package test data
origDir <- system.file('extdata', package='PAMmisc')
decDir <- file.path(tempdir(), 'decSR')
decWavs <- decimateWavFiles(origDir, decDir, 10000)
file.remove(decWavs)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.