output time measurements

1 view (last 30 days)
Sonia Wiemann
Sonia Wiemann on 23 Apr 2012
I have a sound signal that has been gated with the code "signal=uint8(output>= .02);" This gives me a list of "0's" and "1's" the 1"s representing the length of pulses in the sound signal. "0" = noise. I have assigned time points with the code "plot((0:length(signal)-1)/44.1, signal); The sampling rate is 44.1 samples in a mS. How could I tell the program to tell me the length of "1" values in mS so I do not have to manually count samples? There would be more than one section of "1's" in the signal.

Answers (0)

Categories

Find more on Audio I/O and Waveform Generation in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!