library(knitr) opts_chunk$set(echo = FALSE, comment = NA)
# Pass arguments dfr <- params$dfr vars <- params$vars mpf <- params$mpf spf <- params$spf rep <- params$rep pe <- params$pe # Check factors structure out <- ck.fs(dfr, c(mpf, spf), rep) nmpf <- out$nl[[1]] nspf <- out$nl[[2]] nrep <- out$nrep dfr <- out$dfr nmis.fac <- out$nmis.fac
There are data for a split-plot design with r nmpf
levels for the main plot factor, r nspf
levels for the sub-plot factor, and r nrep
replications for the main plot factor. The statistical model is
$$
y_{ijk} = \mu + \alpha_i + \beta_j + \gamma_k + (\alpha\beta){ij} + (\alpha\gamma){ik} + (\beta\gamma){jk} + (\alpha\beta\gamma){ijk}
$$
where
In this model $(\alpha\gamma){ik}$ is the error term for the main plot factor, and $(\beta\gamma){jk}$ and $(\alpha\beta\gamma)_{ijk}$ are pooled to form the error term for the split-plot factor.
r if (nmis.fac == 1) paste("Note: There is", nmis.fac, "data row with missing values for classifications factors. This row has been deleted.")
r if (nmis.fac > 1) paste("Note: There are", nmis.fac, "data rows with missing values for classifications factors. These rows have been deleted.")
out <- NULL for (i in 1:length(vars)) out <- c(out, knit_expand('child_spld.Rmd'))
r paste(knit(text = out), collapse = '\n')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.