Message Boards Message Boards

Plot audio data from a dual (stereo) channel file?

Posted 5 years ago

I am a beginner in mathematica.

Currently i am working on audio file my problem is when i extract audio information using BinaryReadList and try to plot it works with mono wav file but cannot get with sterio file. Can anyone help me where i went wrong or how i can get it right. Here a1.wav is a single(mono) channel audio while bird.wav is dual(sterio) channel.

Attachment

Attachment

Attachments:
POSTED BY: Motilal khoirom
5 Replies

Hello I am using Mathematica 14. I used Import to get an MP3 audio file. I did plot the signal which is a 2-Channel signal. My next step is to get a periodogram and I am assuming it works with MP3, but I am running into difficulty in providing what exact parameters are required.I thought I would just prompt Periodogram [Audiofile] but it is not working. It looks like I am missing some basis information Any Help? Many thanks

POSTED BY: Adam Cherad
Posted 5 years ago

Is there a reason for using BinaryReadList? Have you tried Import and AudioPlot?

audio = Import["bird.wav"]
AudioPlot[audio]
POSTED BY: Rohit Namjoshi

Yes, there is a reason for using BinaryReadList, I want to plot in the range(0-255) and BinaryReadList gives me that value. But AudioPlot will give its data value which is (-1 to +1).

POSTED BY: Motilal khoirom
Posted 5 years ago
audio = Import["bird.wav"]
data = AudioData[audio, "SignedInteger8"] + 128

Suggest you take a look at the extensive documentation on the audio capabilities of WL.

POSTED BY: Rohit Namjoshi

I want to plot the values from BinaryReadList, as I am going to use it in further calculations thanks.

POSTED BY: Motilal khoirom
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract