Last chance! 50% off unlimited learning
Sale ends in
oa.design(ID=NULL, nruns=NULL, nfactors=NULL, nlevels=NULL,
factor.names = if (!is.null(nfactors)) {
if (nfactors
oacat$name
;
users can also specify names of their own designs here (cf. details).
ID
must be of class oa
ID
or if
the smallest possible array is to be foundnlevels
is a single number and
factor.names
is omitted;
can otherwise determined from length of factor.names
,
nlevels
or col
nfactors
entries or single number;
can be omitted, if obvious from factor.names
or if ID
and columns
are given or if all columns of ID
arFrF2
ID
;
must not be specified, if ID
is omitted;
the entries assign columns of the array to the factorsrepeat.only
determines, whether these are real replications
or repeated measurements only. Note that replications are not considered for
accomodation of oa.design
returns a data frame of S3 class design
with attributes attached. Factors with numerical levels are numeric, factors with
character levels are factors. The content of the attributes in class design
depends
on the specific type of design used.
origin
and comment
return the respective attribute of the orthogonal array.oa.design
assigns factors to the columns of orthogonal arrays that are
available within package oacat
. The design names also indicate the number of runs and the numbers of factors
for each number of levels, e.g. L18.2.1.3.7 is an 18 run design with one factor with
2 levels and seven factors with 3 levels each.
oa
is the S3 class used for orthogonal arrays. Objects of class oa
should at least have
the attribute oa.design
with parameter ID
.
Requirements for the arrays:
Factor levels must be coded as a numbers from 1 to number of levels.
The array must be of classes oa
and matrix
.
The array should have an attribute origin
.
The array can have an attribute comment
;
this should be used for mentioning specific properties, e.g.
for the L18.2.1.3.7 that the interaction of the first two factors
can be estimated.
Users are encouraged to send additional arrays to the package maintainer.
The requirements for these are the same as listed above, with attribute origin
being a MUST in this case.
Currently, package DoE.base
contains the orthogonal arrays from Warren Kuhfelds
collection of oa.design
returns a full factorial, replicated for enough degrees of freedom, if necessary.
Note that replications specified with option replications
are not counted in determining
residual degrees of freedom for min.resid.df
.
Default factor names are the first elements of the character vector Letters
,
or the factors position numbers preceded by capital F in case of more than 50 factors.FrF2
, oa.design
, pb
## smallest available array for 6 factors with 3 levels each
oa.design(nfactors=6,nlevels=3)
## level combination for which only a full factorial is (currently) found
oa.design(nlevels=c(4,3,3,2))
## array requested via factor.names
oa.design(factor.names=list(one=c("a","b","c"), two=c(125,275), three=c("old","new"), four=c(-1,1), five=c("min","medium","max")))
## array requested via character factor.names and nlevels (with a little German lesson for one two three four five)
oa.design(factor.names=c("eins","zwei","drei","vier","fuenf"),nlevels=c(2,2,2,3,7))
## array requested via explicit name, Taguchi L18
oa.design(ID=L18)
## array requested via explicit name, with column selection
oa.design(ID=L18.3.6.6.1,columns=c(2,3,7))
## array requested with nruns, not very reasonable
oa.design(nruns=12, nfactors=3, nlevels=2)
## array requested with min.residual.df
oa.design(nfactors=3, nlevels=2, min.residual.df=12)
Run the code above in your browser using DataLab