ck.f | R Documentation |
This function checks the frequencies for a full factorial.
ck.f(trait, factors, rep, dfr)
trait |
The name of the column for the trait to analyze. |
factors |
The names of the columns that identify the factors. |
rep |
The name of the column that identifies the replications, |
dfr |
The name of the data frame. |
The number of treatments without data (nt.0
), the number of
treatments that appear more than once in a given replication (nt.mult
),
the number of missing values nmis
, the proportion of missing values
(pmis
), the number of factors (nf
), the number of levels of each
factor (nl
), the number of replications (nrep
), a table with frequencies
of valid cases for each combination of the levels of the factors (tf
), a table
with frequencies of valid cases for each combination of the levels of the factors in
each replication (tfr
), and the number of rows in the data frame with
missing values for factors (nmis.fac
).
Raul Eyzaguirre.
# Create a design
A <- paste0("a", 1:5)
B <- paste0("b", 1:3)
dfr <- cr.f(c("A", "B"), list(A, B), "rcbd", 3, 10)
dfr <- dfr$book
# Create some random data
dfr$y <- rnorm(45)
# Delete some values
dfr[c(4, 5, 12), 'y'] <- NA
# Check the design
ck.f("y", c("A", "B"), "block", dfr)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.