The Runs Test

Version 1.0.0.0 (738 Bytes) by Wei Li
Check if the positive and negative runs in the vector x is random or not.
2.4K Downloads
Updated 30 Jan 2004

No License

%PURPOSE: check if the positive and negative runs in the vector x is random or not.
%-----------------------------
%USAGE: z=runtest(x)
%where: z is the z stat for a run
% x=a vector variable (nobs x 1)
%-----------------------------
%
%The function could be used on any data with a binomial distribution.
%But the user need to assign positivity and negativity to the two states in
%the data.
%
%Reference: Siegal (1956), Nonparametric Statistics.

Cite As

Wei Li (2024). The Runs Test (https://www.mathworks.com/matlabcentral/fileexchange/4421-the-runs-test), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R13
Compatible with any release
Platform Compatibility
Windows macOS Linux

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