% -*- texinfo -*- % @deftypefn {Function File} {[@var{pval}, @var{chisq}, @var{df}] =} chisquare_test_independence (@var{x}) % Perform a chi-square test for independence based on the contingency % table @var{x}. Under the null hypothesis of independence, % @var{chisq} approximately has a chi-square distribution with % @var{df} degrees of freedom. % % The p-value (1 minus the CDF of this distribution at chisq) of the % test is returned in @var{pval}. % % If no output argument is given, the p-value is displayed. % @end deftypefn