wav format data type in matlab

Hi, I found that data was in int type in wav file, but when I input the wav file into matlab using wavread(), I found that the data was in float type. Can someone tell me why?

 採用された回答

Wayne King
Wayne King 2012 年 5 月 25 日

1 投票

You most likely did not use the format option available in wavread.m
[y,fs] = wavread(file,'native');
If omitted, this defaults to double-precision.

1 件のコメント

Daniel Shub
Daniel Shub 2012 年 5 月 25 日
Good answer ...

サインインしてコメントする。

その他の回答 (1 件)

Daniel Shub
Daniel Shub 2012 年 5 月 25 日

0 投票

You should read the documentation to WAVREAD
doc wavread
You want
[Y,...]=WAVREAD(...,'native')

1 件のコメント

Susan
Susan 2012 年 5 月 26 日
Yes,thank you. The version of my matlab is 6.0, which doesn't support this format. I update the version to 2010, and the problem had been solved.

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeMATLAB についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by