Estimates the lambda value for data transformation

transf(response, f1, f2 = NA, f3 = NA, block = NA, line = NA, column = NA)

## Arguments

response

Numerical vector containing the response of the experiment.

f1

Numeric or complex vector with factor 1 levels

f2

Numeric or complex vector with factor 2 levels

f3

Numeric or complex vector with factor 3 levels

block

Numerical or complex vector with blocks

line

Numerical or complex vector with lines

column

Numerical or complex vector with columns

## Value

Returns the value of lambda and/or data transformation approximation, according to Box-Cox (1964)

## References

Box, G. E., Cox, D. R. (1964). An analysis of transformations. Journal of the Royal Statistical Society: Series B (Methodological), 26(2), 211-243.

## Author

Gabriel Danilo Shimizu, shimizu@uel.br

Leandro Simoes Azeredo Goncalves

Rodrigo Yudi Palhaci Marubayashi

## Examples


#================================================================
# Completely randomized design
#================================================================
data("pomegranate")
with(pomegranate, transf(WL,f1=trat))

#>
#> ------------------------------------------------
#> Box-Cox Transformation (1964)
#>
#> Lambda=-0.8686869
#> ------------------------------------------------
#> Suggestion:
#> 1/Y
#>
#> ou:Yt=(Y^lambda-1)/lambda

#================================================================
# Randomized block design
#================================================================
data(soybean)
with(soybean, transf(prod, f1=cult, block=bloc))

#>
#> ------------------------------------------------
#> Box-Cox Transformation (1964)
#>
#> Lambda=2
#> ------------------------------------------------
#> Suggestion:
#>
#>
#> ou:Yt=(Y^lambda-1)/lambda

#================================================================
#================================================================
data(cloro)
with(cloro, transf(resp, f1=f1, f2=f2))

#>
#> ------------------------------------------------
#> Box-Cox Transformation (1964)
#>
#> Lambda=0.5454545
#> ------------------------------------------------
#> Suggestion:
#> square root (sqrt(Y))
#>
#> ou:Yt=(Y^lambda-1)/lambda

#================================================================
#================================================================
data(cloro)
with(cloro, transf(resp, f1=f1, f2=f2, block=bloco))

#>
#> ------------------------------------------------
#> Box-Cox Transformation (1964)
#>
#> Lambda=0.5050505
#> ------------------------------------------------
#> Suggestion:
#> square root (sqrt(Y))
#>
#> ou:Yt=(Y^lambda-1)/lambda