a formula containing the variables to be crosstabulated
data
the data frame from which to select the variables
varnames
optional labels for the variables (defaults to names(data))
chisq
logical - whether to display chi squared test(s) of the table(s)
phi
whether to calculate and display the phi coefficient
of association - only for 2x2 tables
Value
The result of calculate.xtab if there is only one table to display,
otherwise nil.
Details
xtab will accept a formula referring to columns in a data frame or two explicit
variable names.
It calls calculate.xtab for the calculations and displays one or more tables of
results by calling print.xtab.