fid = fopen(filename, 'w', 'ieee-be');
fwrite(fid, nSamples, 'int32');
fwrite(fid, sampPeriod, 'int32');
fwrite(fid, sampSize, 'int16');
fwrite(fid, parmKind, 'int16');
for i = 1:nSamples
for j = 1:numVecHead
fwrite(fid, data(j, i), 'float32');
I have some given code about writing a HTK file, but I am not sure what is the parameter of it. Let's say I am using audiorecorder to record a sound.
r = audiorecorder(16000,16,1);
After I got a audio data (x) from r, what do I need to fill into the parameter of the code?
nSamples, sampPeriod, sampSize, parmKind, numVecHead