You are now following this Submission
- You will see updates in your followed content feed
- You may receive emails, depending on your communication preferences
this function performs the Mantel-Haenszel test comparing two survival curves and returns the p-value. It takes in the total number of patients, a list of all event times (including censoring and loss) and a binary array the same size specifying which of the events happened due to loss/censoring.
It also plots the survival curves if you have the Statistics and Machine Learning Toolbox (otherwise comment out lines 66-72).
See attached example files for how to use.
Cite As
Peter Ferjancic (2026). Mantel-Haenszel test (https://www.mathworks.com/matlabcentral/fileexchange/62076-mantel-haenszel-test), MATLAB Central File Exchange. Retrieved .
General Information
- Version 1.0.0.0 (1.72 KB)
MATLAB Release Compatibility
- Compatible with any release
Platform Compatibility
- Windows
- macOS
- Linux
| Version | Published | Release Notes | Action |
|---|---|---|---|
| 1.0.0.0 |
