% Function file: [H, P, h] = bootmode (x, m, B, kernel)
%
% This function tests whether the distribution underlying the univariate
% data in vector x has m modes. The method employs the smooth bootstrap
% as described [1].
%
% The parsimonious approach is to consider a successively increasing
% number of modes until the null hypothesis (H0) is accepted (i.e. H=0),
% where H0 corresponds to the number of modes being equal to m.
%
% x is the vector of data
%
% m is the number of modes for hypothesis testing
%
% B is the number of bootstrap replicates
%
% kernel can be 'Gaussian' (default) or 'Epanechnikov'
%
% H=0 indicates that the null hypothesis cannot be rejected at the 5%
% significance level. H=1 indicates that the null hypothesis can be
% rejected at the 5% level.
%
% P is the achieved significance level using the bootstrap test.
%
% h is the critical bandwidth (i.e. the smallest bandwidth achievable to
% obtain a kernel density estimate with m modes)
%
% Bibliography:
% [1] Efron and Tibshirani. Chapter 16 Hypothesis testing with the
% bootstrap in An introduction to the bootstrap (CRC Press, 1994)
%
% bootmode v1.1 (22/04/2019)
% Author: Andrew Charles Penn
% https://www.researchgate.net/profile/Andrew_Penn/
Zitieren als
Andrew Penn (2024). bootmode (https://www.mathworks.com/matlabcentral/fileexchange/66671-bootmode), MATLAB Central File Exchange. Abgerufen .
Kompatibilität der MATLAB-Version
Plattform-Kompatibilität
Windows macOS LinuxKategorien
Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Live Editor erkunden
Erstellen Sie Skripte mit Code, Ausgabe und formatiertem Text in einem einzigen ausführbaren Dokument.
Version | Veröffentlicht | Versionshinweise | |
---|---|---|---|
1.1.0.0 | - Correction to example data set provided in comments
|
||
1.0.0.0 |