Level Crossing Rate

The function calculates Level Crossing Rate (LCR).
4.7K Downloads
Updated 9 Dec 2002

No License

LCR calculates Level Crossing Rate, that is a number of crossings (in the positive direction) of an input vector through a given threshold vector.
[x,t] = lcr( sig, thr );

The crossings are calculated for all the values of the input threshold vector. The input signal has to be a vector.

Example:
n = randn( 1, 1000 );
x = lcr( n, -5:0.1:5 );
plot( t, x );

Cite As

Adrian Bohdanowicz (2024). Level Crossing Rate (https://www.mathworks.com/matlabcentral/fileexchange/2817-level-crossing-rate), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R12
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Periodic Waveform Generation in Help Center and MATLAB Answers

Community Treasure Hunt

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

Start Hunting!
Version Published Release Notes
1.0.0.0