| bucss_tidiers | R Documentation |
tidy() returns the compact estimate view, as the sibling package
DMAR's sample size planners do: one row with term
("sample_size"), estimate (the necessary sample size in the
design's unit, which the result's sample_size_unit attribute names),
and power (the power of the plan the result reports; see
actual_power on the planner's help page). glance() returns
the one-row wide view: the same three columns, then one column per row of
the result, namely the sample size row, total_N where applicable,
actual_power, ncp_adjusted, the planning effect size (the
row whose name ends in _planning, such as smd_planning), and
every echoed planning input, together with the design, the effect tested,
the unit, the planned test's degrees of freedom where the design has them,
and the assurance ceiling.
## S3 method for class 'bucss_plan'
tidy(x, ...)
## S3 method for class 'bucss_plan'
glance(x, ...)
x |
An object of class |
... |
Ignored. |
These methods come from the generics package and need no extra setup;
the verbs are re-exported by BUCSS, so tidy(result) and
glance(result) work as soon as the package is loaded. The result is
also an ordinary data.frame, so the long view and the stored full
precision values remain available directly, for example
result$value[result$term == "ncp_adjusted"].
A one-row data.frame. For tidy(), the columns
term, estimate, and power. For glance(), the
wide summary described above. Both stop with an explanation if the object
no longer has the shape of a single plan (for example, several plans
stacked with dplyr::bind_rows(), or a plan with a row removed by
dplyr::filter(); both keep the class).
Ken Kelley (kkelley@nd.edu) and Samantha F. Anderson (samantha.f.anderson@asu.edu)
result <- ss_buc_factorial_anova(F_observed = 5, N = 120, levels_A = 2,
levels_B = 3, effect = "factor_B")
# Compact estimate view, as in DMAR: the sample size and its power.
tidy(result)
tidy(result)$estimate
# One-row wide view: every quantity and echoed input as a column.
glance(result)
glance(result)$total_N
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.