%% Pulse Period of Bilevel Waveform
% Compute the pulse period of a bilevel waveform with two positive-polarity transitions. The sample rate is 4 MHz.

load('pulseex.mat','x','t')

p = pulseperiod(x,t)

%
% Annotate the pulse period on a plot of the waveform.

pulseperiod(x,t);

% Copyright 2015 The MathWorks, Inc.