www.gusucode.com > signal 案例源码程序 matlab代码 > signal/StateLevelsUsingMeansOfSubhistogramsExample.m

    %% State Levels Using Means of Subhistograms
% Estimate the low and high-state levels of 2.3 V underdamped clock data
% sampled at 4 MHz.

% Copyright 2015 The MathWorks, Inc.


%%
% Use the default number of bins and means of the subhistograms to estimate
% the state levels. Plot the clock data with the lines indicating the
% estimated low and high-state levels.

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

statelevels(x,1e3,'mean')