chi2gof
Chi-square goodness-of-fit test.
📝Syntax
h = chi2gof(x)
h = chi2gof(x, Name, Value)
[h, p, stats] = chi2gof(...)
📄Description

chi2gof performs a chi-square goodness-of-fit test for a real numeric vector. Non-finite observations and nonpositive or non-finite frequencies are omitted.

Name-value arguments include Alpha, NBins, Ctrs, Edges, CDF, Expected, Frequency, NParams, and EMin. CDF can be a two-column matrix or a function handle.

The stats output contains chi2stat, df, edges, O, and E.

💡Examples
x = norminv(((1:100) - 0.5) / 100);
[h, p, stats] = chi2gof(x)
🔗See Also
chi2cdfkstestcrosstab
🕔Version History
Version Description
2.0.0 initial version
Edit this page on GitHub