fraction {blocksdesign}R Documentation

Optimum treatment set from a candidate set of treatments


Finds an optimum set of treatments from a candidate set of treatments for any arbitrary treatments design formula.


  treatments_model = NULL,
  restriction_model = NULL,
  searches = 50



is a data frame or a list containing a candidate set of factorial treatments.


is the required number of treatments in the fractional set of treatments.


is a model formula for the required treatments design.


is a model formula which is a subset of the treatments_model formula and which fixes those treatment factors contained in the restriction model formula.


are the maximum number of searches for selecting the best optimization.


The candidate set treatments will normally contain one or more complete sets of treatment replicates. The algorithm re-arranges the rows of the treatments set to ensure that the first size rows of the optimized treatments set contains the optimized treatment fraction. The maximum replication of any treatment is the number of times that treatment occurs in the candidate treatment set and for a polynomial response surface design extra replication of the candidate set may be necessary to allow for differential replication of the design points. The design is optimized with respect to the treatments_model conditional on the treatment factors in the restriction_model being held constant. The restriction_model must be a subset of the full treatments_model otherwise the design will be fully fixed and no further optimization will be possible. Fitting a non-null restriction_model allows sequential optimization with each successively treatments_model optimized conditional on all previously optimized models. The D-optimal efficiency of the design for the optimized treatment set is calculated relative to the D-optimal efficiency of the design for the candidate treatment set.

The default treatments_model parameter is an additive model for all treatment factors.


A list containing:

See Also



#' ## Plackett and Burman (P&B) type design for eleven 2-level factors in 12 runs 
## NB. The algorithmic method is unlikely to succeed for larger P&B type designs. 

GF = list(F1 = factor(1:2,labels=c("a","b")), F2 = factor(1:2,labels=c("a","b")), 
                 F3 = factor(1:2,labels=c("a","b")), F4 = factor(1:2,labels=c("a","b")),
                 F5 = factor(1:2,labels=c("a","b")), F6 = factor(1:2,labels=c("a","b")),
                 F7 = factor(1:2,labels=c("a","b")), F8 = factor(1:2,labels=c("a","b")), 
                 F9 = factor(1:2,labels=c("a","b")), F10= factor(1:2,labels=c("a","b")), 
                 F11= factor(1:2,labels=c("a","b")) )
model = ~ F1 + F2 + F3 + F4 + F5 + F6 + F7 + F8 + F9 + F10 + F11

## Factorial treatment designs defined by sequentially fitted factorial treatment models
## 4 varieties by 3 levels of N by 3 levels of K assuming degree-2 treatment model in 24 plots.
## The single stage model gives an unequal split for the replication of the four varieties
## whereas the two stage model forces an equal split of 6 plots per variety.
## The single stage model is slightly more efficient overall (about 1.052045 versus 1.043662)
## but unequal variety replication is undesirable if all varieties are equally important.

## model terms
treatments = list(Variety = factor(1:4), N = 1:3, K = 1:3)
variety_model = ~ Variety
full_model = ~ (Variety + N + K)^2  + I(N^2) + I(K^2)

## single stage model
opt_full_treatments = fraction(treatments,24,full_model,searches=10)
table(opt_full_treatments$TF[,1]) # variety replication

## two stage model
opt_var_treatments  = fraction(treatments,24,variety_model,searches=10)
opt_full_treatments = fraction(opt_var_treatments$fullTF,24,full_model,variety_model,searches=10)
table(opt_full_treatments$TF[,1]) # variety replication

[Package blocksdesign version 4.9 Index]