[R] from wav to R

Uwe Ligges ligges at statistik.uni-dortmund.de
Wed Dec 18 17:02:06 CET 2002


Petr Pikal wrote:
> Dear all
> 
> I would like to perform frequency analysis of a sound (noise) 
> recorded as a wav file (I would like to compare different sounds if 
> they vary in frequency and how much). I know there exists some 
> packages (Cool Edit) for doing frequency analysis of sounds but I 
> wonder if anybody tried to do it in R.
> 
> I found a package sound. It enables to play with wav files, to 
> append them and to make some filtrations. But if I wanted to 
> invoke a spectrum() function it did not work with sound object.
> 
> Please can somebody give me a hint where to look or how to 
> convert wav file to some kind of object analysable by R functions.

If you did
  mywave <- loadSample(.....)
the data you are trying to analyze is in the matrix
  mywave$sound


Uwe Ligges




More information about the R-help mailing list