WT {LHD} | R Documentation |
Williams Transformation
Description
WT
returns a matrix after implementing the Williams transformation
Usage
WT(X, baseline = 1)
Arguments
X |
A matrix object. In general, |
baseline |
A integer, which defines the minimum value for each column of the matrix. The default is set to be 1. |
Value
If all inputs are logical, then the output will be a matrix whose sizes are the same as input matrix.
References
Williams, E. J. (1949) Experimental designs balanced for the estimation of residual effects of treatments. Australian Journal of Chemistry, 2, 149-168.
Examples
#create a toy LHD with 5 rows and 3 columns
toy=rLHD(n=5,k=3);toy
toy2=toy-1;toy2 #make elements of "toy" become 0,1,2,3,4
#Implementing Williams transformation on both toy and toy2:
#The result shows that "WT" function is able to detect the
#elements of input matrix and make adjustments.
WT(toy)
WT(toy2)
#Change the baseline
WT(toy,baseline=5)
WT(toy,baseline=10)
[Package LHD version 1.3.3 Index]