2
$\begingroup$

I have biological signals sampled at 1 kHz. The signals tend to behave fairly simply, sinusoidally. The software I've used to collect these data uses their proprietary format (*.adicht) and so I have to export to something I can work with in MATLAB, for example. I also have audio recordings from the same sessions for importing to praat, which accepts WAV files.

The formats available for export include WAV, tab-delineated text, and an unwieldy .mat conversion process that sometimes causes the program to crash.

My question is whether there is a disadvantage to exporting everything as WAVs, or a specific reason why I would want to use text over WAVs? Is there a drawback to using the WAV format for non-audio signals, or is it just unnecessary?

It will save me a lot of time if I export to a single format, and since I know I need WAV for audio analysis in praat, it would be easier just to export the non-sound signals that way as well (this program does not handle macros/batch scripting very well).

$\endgroup$
1
$\begingroup$

.wav is basically just a raw array of numbers in their native binary representation, plus a header that specifies sample rate etc.. None of this is really specific to audio, so, yes, .wav is definitely usable without problems, and in fact will be much more efficient than a text-based format.

In one undergrad experiment I did, we sampled a Geiger counter with a consumer sound card, and used .wav files as the basis of decay statistics. It worked just fine. And I've heard of audio components being used for serious geophysics measurements. As long as you don't get near 20 kHz, there aren't generally any problems; above, all bets are off though.

$\endgroup$
2
$\begingroup$

I think WAV will be a good format for your data as it supports:

  • Integer Hz sampling frequencies (like your 1000 Hz).
  • Integer sample formats (like 16-bit, 24-bit, 32-bit).
  • A floating point sample format (32-bit IEEE float).
  • Multiple channels.
  • Seeking (quickly reading the file at a specific time point in the audio).

Other nice things about WAV:

  • You can use FLAC to compress WAV files for storage and transfer.
  • WAV files can also contain non-PCM data (such as markers and metadata).
$\endgroup$
  • 1
    $\begingroup$ FLAC isn't WAV, though. It only supports integer formats, for instance, negating one of your Pros. $\endgroup$ – endolith May 10 '20 at 22:07
1
$\begingroup$

WAV files are lossless, so there should be no disadvantage to using them. For a sanity check, you should try WAV and text and make sure you get the same results in the end. Text files would be advantageous if you want to excerpt portion and import them into spreadsheets or something for additional analysis. If the WAV files work for your purposes, then they should be just fine.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.