- formula
object of class formula
,
potentially with
a subject scale or subscale
on the left-hand side and
variables to tabulate
on the right-hand side.
When the left-hand side of the
formula is omitted and returnMeans
is TRUE
,
then the default subject scale or subscale is used.
You can find the default composite scale and all subscales
using the function showPlausibleValues
.
Note that the order of the right-hand side variables affects the output.
- data
object of class edsurvey.data.frame
. See readNAEP
for how to generate an edsurvey.data.frame
.
- weightVar
character string indicating the weight variable to use.
Note that only the name of the
weight variable needs to be included here, and any
replicate weights will be automatically included.
When this argument is NULL
, the function uses the default.
Use showWeights
to find the default.
- jrrIMax
a numeric value; when using the jackknife variance estimation method, the default estimation option, jrrIMax=1
, uses the
sampling variance from the first plausible value as the component for sampling variance estimation. The \(V_{jrr}\)
term (see the Details section of
lm.sdf
to see the definition of \(V_{jrr}\)) can be estimated with any number of plausible values, and values larger than the number of
plausible values on the survey (including Inf
) will result in all of the plausible values being used.
Higher values of jrrIMax
lead to longer computing times and more accurate variance estimates.
- pctAggregationLevel
the percentage variable sums up to 100 for the first
pctAggregationLevel
columns.
So, when set to 0
, the PCT
column adds up to 1
across the entire sample.
When set to 1
, the PCT
column adds up to 1
within each level of the first variable on the
right-hand side of the formula; when set to 2
,
then the percentage
adds up to 100 within the interaction of the
first and second variable, and so on.
Default is NULL
, which will result in the
lowest feasible aggregation level.
See Examples section.
- returnMeans
a logical value; set to TRUE
(the default) to get the MEAN
and
SE(MEAN)
columns in the returned table described in the Value section.
- returnSepct
set to TRUE
(the default) to get the SEPCT
column in the returned table described in the Value section.
- varMethod
a character set to jackknife
or Taylor
that indicates the variance estimation method
to be used.
- drop
a logical value. When set to the default value of FALSE
, when a single column is returned, it is still represented as a data.frame
and is
not converted to a vector.
- dropOmittedLevels
a logical value. When set to the default value of TRUE
, drops those levels of all factor variables that are specified
in an edsurvey.data.frame
. Use print
on an edsurvey.data.frame
to see the omitted levels.
- defaultConditions
a logical value. When set to the default value of TRUE
, uses the default conditions stored in an edsurvey.data.frame
to subset the data. Use print
on an edsurvey.data.frame
to see the default conditions.
- recode
a list of lists to recode variables. Defaults to NULL
. Can be set as
recode
=
list(var1
=
list(from
=
c("a", "b", "c"),
to
=
"c"))
.
- returnVarEstInputs
a logical value set to TRUE
to return the
inputs to the jackknife and imputation variance
estimates, which allows for
the computation
of covariances between estimates.
- omittedLevels
this argument is deprecated. Use dropOmittedLevels
.