View source: R/crosstab with weights.R
BSkyCrossTable | R Documentation |
Creates crosstab with row, column and layer variables and optionally displays the following Expected counts Row and column percentages Unstandardized, standardized and adjusted residuals Chisq with odds ratio, McNemar and Fisher statistics
BSkyCrossTable(
data = NULL,
x = NA,
y = NA,
layers = NA,
weight = NA,
digits = 3,
max.width = 5,
expected = FALSE,
prop.r = FALSE,
prop.c = FALSE,
prop.t = FALSE,
prop.chisq = FALSE,
chisq = FALSE,
fisher = FALSE,
mcnemar = FALSE,
resid = FALSE,
sresid = FALSE,
asresid = FALSE,
missing.include = TRUE,
dnn = NULL,
datasetname = NULL,
bSkyHandleSplit = TRUE,
long_table = FALSE,
debug = FALSE
)
x |
row variable |
y |
column variable |
layers |
one or more variables for layers |
expected |
Expected counts are generated if this is TRUE |
prop.r |
Row percentages are produced if this is TRUE |
prop.c |
Column percentages are generated if this is TRUE |
chisq |
if TRUE generates chi-square table |
resid |
if TRUE, unstandardized residual are generated |
sresid |
if TRUE, standardized residuals are generated |
asresid |
if TRUE, adjusted residuals are generated |
datasetname |
Name of the dataset from which x,y and layers (variables) are chosen |
weights |
a numeric variable containing the frequency weights |
A list with the results
BSky_Multiway_Cross_Tab = BSkyCrossTable(x=c('manufact'),y=c('model'),
layers=c('type'),datasetname='Dataset2',
chisq = FALSE,prop.r=FALSE,prop.c=FALSE,
resid=FALSE,sresid=FALSE,expected=FALSE,
asresid=FALSE)
BSkyFormat(BSky_Multiway_Cross_Tab)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.