Invisibly returns an object of classes th_test and htest containing the statistic, degrees of freedom, p-value, critical value, decision, observed frequencies, and expected frequencies. When plot = TRUE, an educational graph is produced as a side effect.
Arguments
dadosX
Vector identifying the groups or populations. Use NULL when a frequency table is supplied.
dadosY
Vector containing the response categories. Use NULL when a frequency table is supplied.
FO
Matrix of observed frequencies.
alfa
Significance level.
Ha
Right-tailed alternative. Use 2 or "greater"; other values are rejected.
r
Retained for backward compatibility. It must be zero; Pearson degrees of freedom are used without adjustment.
plot
Logical. If TRUE (default), draw the educational graph; if FALSE, return the result without plotting.
Author
Willian Silva Barros
Details
The function accepts individual categorical observations or an observed frequency matrix. The standard omnibus chi-square homogeneity test has an upper-tail rejection region.