random.factors {designr} | R Documentation |
Extract factors by type
Description
From a given design, extract contained random or fixed factors as a list.
Usage
random.factors(design, include_interactions = TRUE)
fixed.factors(design)
Arguments
design |
The factor design to check. |
include_interactions |
Should random factor interactions be included? |
Value
A list of factors that are either fixed or random.
Functions
-
random.factors()
: Return fixed factors
Examples
des <- fixed.factor("Factor1", c("1A","1B")) +
fixed.factor("Factor2", c("2A","2B")) +
random.factor("Subject", c("Factor1"))
random.factors(des)
fixed.factors(des)
stopifnot(setequal(names(random.factors(des)), c("Subject")))
stopifnot(setequal(names(fixed.factors(des)), c("Factor1","Factor2")))
[Package designr version 0.1.13 Index]