Package 'CANE'

Title: Comprehensive Groups of Experiments Analysis for Numerous Environments
Description: Pooled analysis of a series of designed experiments repeated over locations, seasons or years, where treatment-by-environment interaction is of primary interest. One design-specific function call performs environment-wise analysis of variance, formal testing of homogeneity of error variances, an optional variance-stabilising transformation, pooled analysis of variance with the correct error stratum for every effect, and multiple comparison of means. Five classical designs are supported: completely randomised ('PooledCRD()'), randomised block ('PooledRBD()'), Latin square ('PooledLSD()'), split plot ('PooledSPD()') and strip plot ('PooledStPD()'). Homogeneity of error variances is assessed by Bartlett's test computed on the environment-wise error mean squares as in Bartlett (1937) <doi:10.1098/rspa.1937.0109>, and by the median-centred Brown-Forsythe form of Levene's test <doi:10.1080/01621459.1974.10482955>, which is robust to non-normality. When variances are heterogeneous, Aitken's transformation (division of each observation by the square root of the error mean square of its own environment) may be applied, and treatment means are reported on both the transformed and the original scale. For split plot and strip plot designs every effect is tested against its proper error term, and mean separation uses the error mean square and degrees of freedom of the corresponding stratum. The statistical theory is given in Cochran and Cox (1957, ISBN:9780471162032), Gomez and Gomez (1984, ISBN:9780471870928), Dean et al. (2017) <doi:10.1007/978-3-319-52250-0> and Ruiz et al. (2024) <doi:10.1007/978-3-031-65575-3>.
Authors: Vinayaka [aut, cre] (ORCID: <https://orcid.org/0000-0001-5004-0084>), T. Lakshmi Pathy [aut, ctb] (ORCID: <https://orcid.org/0000-0001-8940-7971>), Gopalareddy Krishnappa [aut, ctb] (ORCID: <https://orcid.org/0000-0002-8825-6363>), Shweta Kumari [aut, ctb] (ORCID: <https://orcid.org/0009-0000-4377-2455>), P. Murali [aut, ctb] (ORCID: <https://orcid.org/0000-0002-1149-7097>), P. Govindaraj [aut, ctb], P. Rama Chandra Prasad [aut, ctb] (ORCID: <https://orcid.org/0000-0001-5285-9827>), L.N. Vinaykumar [aut, ctb]
Maintainer: Vinayaka <[email protected]>
License: GPL-3
Version: 0.2.0
Built: 2026-11-05 13:26:01 UTC
Source: https://github.com/vinayaka11442/cane

Help Index


Print and Summary Methods for CANE Objects

Description

Compact display of the objects returned by the pooled analysis functions of the package.

Usage

## S3 method for class 'cane_anova'
print(x, digits = 4, ...)

## S3 method for class 'cane_comparison'
print(x, digits = 4, ...)

## S3 method for class 'cane_bartlett'
print(x, digits = 4, ...)

## S3 method for class 'cane_note'
print(x, ...)

## S3 method for class 'cane'
print(x, digits = 4, ...)

## S3 method for class 'cane'
summary(object, digits = 4, ...)

Arguments

x, object

An object returned by PooledCRD, PooledRBD, PooledLSD, PooledSPD or PooledStPD.

digits

Number of significant digits used when printing.

...

Further arguments, currently ignored.

Value

print methods return their argument invisibly. summary.cane returns, invisibly, a list with the pooled ANOVA table, the variance-homogeneity tests and the pooled treatment groups.


Illustrative Completely Randomised Design Series

Description

A balanced series of completely randomised experiments: four treatments, three environments and five experimental units per treatment within each environment.

Usage

crd_example

Format

A data frame with 60 rows and 3 variables:

Loc

Factor with 3 levels, the environment.

Treatment

Factor with 4 levels.

Yield

Numeric response.

Details

Simulated from a known additive model with a treatment main effect, an environment main effect, no treatment-by-environment interaction and homogeneous error variances, so that the expected outcome of the analysis is known. Provided for documentation, examples and regression tests.

Examples

data(crd_example)
str(crd_example)

Illustrative Latin Square Design Series

Description

Three 4 x 4 Latin squares, one per environment, with a different cyclic arrangement in each environment.

Usage

lsd_example

Format

A data frame with 48 rows and 5 variables:

Location

Factor with 3 levels, the environment.

Row

Factor with 4 levels, the row of the square.

Column

Factor with 4 levels, the column of the square.

Treatment

Factor with 4 levels.

Yield

Numeric response.

Details

Simulated from a known model containing treatment, environment, row and column effects and no treatment-by-environment interaction. Rows and columns are specific to each environment, which is why the pooled model nests them within environment.

Examples

data(lsd_example)
with(lsd_example, table(Treatment, Row, Location))

Pooled Analysis of a Series of Completely Randomised Designs

Description

Performs the classical pooled analysis of variance for a completely randomised design (CRD) repeated over several environments (locations, seasons or years). The function carries out the environment-wise analysis, tests homogeneity of the error variances, optionally applies Aitken's variance-stabilising transformation, fits the pooled model including the treatment-by-environment interaction, and separates treatment means.

Usage

PooledCRD(
  data,
  Response,
  Location,
  Treatment,
  alpha = 0.05,
  Mult_Comp_Test = 1,
  transform = c("auto", "always", "never"),
  env_effect = c("fixed", "random")
)

Arguments

data

A data frame containing the experimental data. Rows with missing values in the variables used are dropped with a warning.

Response

Character string naming the numeric response variable.

Location

Character string naming the factor that identifies environments (locations, seasons or years).

Treatment

Character string naming the treatment factor.

alpha

Significance level used for the variance-homogeneity test and for the multiple comparison procedure. Default 0.05.

Mult_Comp_Test

Integer selecting the multiple comparison procedure: 1 = Tukey's honestly significant difference (HSD) test, 2 = Duncan's multiple range test (DMRT), 3 = Fisher's least significant difference (LSD) test. Option 3 makes no adjustment for multiplicity and is intended for a small number of pre-planned comparisons; a warning is issued if it is requested for more than three treatments.

transform

One of "auto" (default; transform only when the variances are judged heterogeneous at level alpha), "always" or "never".

env_effect

One of "fixed" (default) or "random". With "random" each treatment main effect is tested against its interaction with environment, and in split plot and strip plot designs the interaction of the two treatment factors is tested against the three-way interaction with environment. The pooled comparison of means then uses the same mean square and degrees of freedom as the F-test of the factor compared. With few environments that interaction has few degrees of freedom; if it has fewer than two, the Tukey and Duncan comparisons for that factor are not computed and a warning is issued.

Details

The model fitted within environment jj is

Yijk=μj+τij+ϵijkY_{ijk} = \mu_j + \tau_{ij} + \epsilon_{ijk}

and the pooled model is

Yijk=μ+βj+τi+(τβ)ij+ϵijk,Y_{ijk} = \mu + \beta_j + \tau_i + (\tau\beta)_{ij} + \epsilon_{ijk},

where βj\beta_j is the environment effect, τi\tau_i the treatment effect and (τβ)ij(\tau\beta)_{ij} their interaction. A completely randomised design has a single error stratum, so every effect is tested against the pooled error mean square when env_effect = "fixed". With env_effect = "random" the treatment main effect is tested against the treatment-by-environment interaction, which is the appropriate denominator when the environments are regarded as a random sample from a target population.

Homogeneity of error variances is tested by Bartlett's statistic computed on the environment-wise error mean squares, each carrying its own error degrees of freedom. Because Bartlett's test is sensitive to non-normality, the median-centred (Brown-Forsythe) form of Levene's test and environment-wise Shapiro-Wilk tests are reported alongside it. Levene's test is computed on the environment-wise residuals; because the residuals of environment jj carry only its error degrees of freedom νj\nu_j (with two replications they occur in exact plus-minus pairs), its denominator degrees of freedom are ∑jνj\sum_j \nu_j rather than N−lN - l. The transform argument lets the user override the automatic decision.

Value

An object of class "cane", a list with components

Design

Name of the design analysed.

Individual_ANOVA

List of environment-wise ANOVA tables.

Location_wise

Environment-wise multiple comparisons, each computed from the error mean square of that environment.

Bartlett_Test

Bartlett's test on the error mean squares. For split plot and strip plot designs, element other_strata gives the same test for the main plot or strip error strata.

Levene_Test

Median-centred Levene (Brown-Forsythe) test.

Normality_Test

Environment-wise Shapiro-Wilk tests.

Transformation

Whether Aitken's transformation was applied, why, the environment-wise error mean squares and the ratio of the largest to the smallest.

Pooled_ANOVA

Pooled ANOVA table, including the error term used as the denominator of each F-test.

Treatments_Comparison

Pooled treatment means, groups and all pairwise differences. When a transformation was applied, means are given on the transformed scale (on which the test was performed) and the arithmetic means on the original scale are reported alongside.

GEI_Note

Advice issued when any interaction of a treatment factor with environment is significant, naming the terms concerned.

Environment_Key

Mapping of environment levels to their error mean square and error degrees of freedom.

Settings

Arguments and software versions used.

References

Aitken, A. C. (1935). On least squares and linear combination of observations. Proceedings of the Royal Society of Edinburgh, 55, 42–48. doi:10.1017/S0370164600014346

Bartlett, M. S. (1937). Properties of sufficiency and statistical tests. Proceedings of the Royal Society of London A, 160, 268–282. doi:10.1098/rspa.1937.0109

Cochran, W. G. and Cox, G. M. (1957). Experimental Designs, 2nd ed. John Wiley and Sons, New York.

Dean, A., Voss, D. and Draguljic, D. (2017). Design and Analysis of Experiments, 2nd ed. Springer, Cham. doi:10.1007/978-3-319-52250-0

Gomez, K. A. and Gomez, A. A. (1984). Statistical Procedures for Agricultural Research, 2nd ed. John Wiley and Sons, New York.

See Also

PooledRBD, PooledLSD, PooledSPD, PooledStPD

Examples

data(crd_example)
out <- PooledCRD(crd_example, Response = "Yield", Location = "Loc",
                 Treatment = "Treatment", alpha = 0.05, Mult_Comp_Test = 1)
out
out$Pooled_ANOVA

Pooled Analysis of a Series of Latin Square Designs

Description

Performs the classical pooled analysis of variance for a Latin square design repeated over several environments, with rows and columns correctly nested within environment.

Usage

PooledLSD(
  data,
  Response,
  Location,
  Treatment,
  Row,
  Column,
  alpha = 0.05,
  Mult_Comp_Test = 1,
  transform = c("auto", "always", "never"),
  env_effect = c("fixed", "random")
)

Arguments

data

A data frame containing the experimental data. Rows with missing values in the variables used are dropped with a warning.

Response

Character string naming the numeric response variable.

Location

Character string naming the factor that identifies environments (locations, seasons or years).

Treatment

Character string naming the treatment factor.

Row

Character string naming the row factor of the square.

Column

Character string naming the column factor of the square.

alpha

Significance level used for the variance-homogeneity test and for the multiple comparison procedure. Default 0.05.

Mult_Comp_Test

Integer selecting the multiple comparison procedure: 1 = Tukey's honestly significant difference (HSD) test, 2 = Duncan's multiple range test (DMRT), 3 = Fisher's least significant difference (LSD) test. Option 3 makes no adjustment for multiplicity and is intended for a small number of pre-planned comparisons; a warning is issued if it is requested for more than three treatments.

transform

One of "auto" (default; transform only when the variances are judged heterogeneous at level alpha), "always" or "never".

env_effect

One of "fixed" (default) or "random". With "random" each treatment main effect is tested against its interaction with environment, and in split plot and strip plot designs the interaction of the two treatment factors is tested against the three-way interaction with environment. The pooled comparison of means then uses the same mean square and degrees of freedom as the F-test of the factor compared. With few environments that interaction has few degrees of freedom; if it has fewer than two, the Tukey and Duncan comparisons for that factor are not computed and a warning is issued.

Details

The model fitted within environment jj is

Yijkm=μj+ρjk+γjm+τij+ϵijkmY_{ijkm} = \mu_j + \rho_{jk} + \gamma_{jm} + \tau_{ij} + \epsilon_{ijkm}

with ρjk\rho_{jk} the row effect and γjm\gamma_{jm} the column effect. In the pooled model rows and columns are nested within environment, because each environment carries its own Latin square: row 1 at one site is a different strip of land from row 1 at another. Nesting gives l(t−1)l(t-1) degrees of freedom each for rows and columns. Treating rows and columns as crossed with environment instead would absorb (l−1)(t−1)(l-1)(t-1) genuine blocking degrees of freedom into the error term and bias every F-test.

Value

An object of class "cane", a list with components

Design

Name of the design analysed.

Individual_ANOVA

List of environment-wise ANOVA tables.

Location_wise

Environment-wise multiple comparisons, each computed from the error mean square of that environment.

Bartlett_Test

Bartlett's test on the error mean squares. For split plot and strip plot designs, element other_strata gives the same test for the main plot or strip error strata.

Levene_Test

Median-centred Levene (Brown-Forsythe) test.

Normality_Test

Environment-wise Shapiro-Wilk tests.

Transformation

Whether Aitken's transformation was applied, why, the environment-wise error mean squares and the ratio of the largest to the smallest.

Pooled_ANOVA

Pooled ANOVA table, including the error term used as the denominator of each F-test.

Treatments_Comparison

Pooled treatment means, groups and all pairwise differences. When a transformation was applied, means are given on the transformed scale (on which the test was performed) and the arithmetic means on the original scale are reported alongside.

GEI_Note

Advice issued when any interaction of a treatment factor with environment is significant, naming the terms concerned.

Environment_Key

Mapping of environment levels to their error mean square and error degrees of freedom.

Settings

Arguments and software versions used.

References

Aitken, A. C. (1935). On least squares and linear combination of observations. Proceedings of the Royal Society of Edinburgh, 55, 42–48. doi:10.1017/S0370164600014346

Bartlett, M. S. (1937). Properties of sufficiency and statistical tests. Proceedings of the Royal Society of London A, 160, 268–282. doi:10.1098/rspa.1937.0109

Cochran, W. G. and Cox, G. M. (1957). Experimental Designs, 2nd ed. John Wiley and Sons, New York.

Dean, A., Voss, D. and Draguljic, D. (2017). Design and Analysis of Experiments, 2nd ed. Springer, Cham. doi:10.1007/978-3-319-52250-0

Gomez, K. A. and Gomez, A. A. (1984). Statistical Procedures for Agricultural Research, 2nd ed. John Wiley and Sons, New York.

See Also

PooledCRD, PooledRBD, PooledSPD, PooledStPD

Examples

data(lsd_example)
out <- PooledLSD(lsd_example, Response = "Yield", Location = "Location",
                 Treatment = "Treatment", Row = "Row", Column = "Column",
                 alpha = 0.05, Mult_Comp_Test = 1)
out
out$Pooled_ANOVA

Pooled Analysis of a Series of Randomised Block Designs

Description

Performs the classical pooled analysis of variance for a randomised block design (RBD) repeated over several environments. This is the workhorse analysis of multi-environment variety and agronomy trials.

Usage

PooledRBD(
  data,
  Response,
  Location,
  Treatment,
  Replication,
  alpha = 0.05,
  Mult_Comp_Test = 1,
  transform = c("auto", "always", "never"),
  env_effect = c("fixed", "random")
)

Arguments

data

A data frame containing the experimental data. Rows with missing values in the variables used are dropped with a warning.

Response

Character string naming the numeric response variable.

Location

Character string naming the factor that identifies environments (locations, seasons or years).

Treatment

Character string naming the treatment factor.

Replication

Character string naming the replication (block) factor.

alpha

Significance level used for the variance-homogeneity test and for the multiple comparison procedure. Default 0.05.

Mult_Comp_Test

Integer selecting the multiple comparison procedure: 1 = Tukey's honestly significant difference (HSD) test, 2 = Duncan's multiple range test (DMRT), 3 = Fisher's least significant difference (LSD) test. Option 3 makes no adjustment for multiplicity and is intended for a small number of pre-planned comparisons; a warning is issued if it is requested for more than three treatments.

transform

One of "auto" (default; transform only when the variances are judged heterogeneous at level alpha), "always" or "never".

env_effect

One of "fixed" (default) or "random". With "random" each treatment main effect is tested against its interaction with environment, and in split plot and strip plot designs the interaction of the two treatment factors is tested against the three-way interaction with environment. The pooled comparison of means then uses the same mean square and degrees of freedom as the F-test of the factor compared. With few environments that interaction has few degrees of freedom; if it has fewer than two, the Tukey and Duncan comparisons for that factor are not computed and a warning is issued.

Details

The model fitted within environment jj is

Yijk=μj+ρjk+τij+ϵijkY_{ijk} = \mu_j + \rho_{jk} + \tau_{ij} + \epsilon_{ijk}

with ρjk\rho_{jk} the effect of replication kk in environment jj. The pooled model is

Yijk=μ+βj+ρk(j)+τi+(τβ)ij+ϵijk,Y_{ijk} = \mu + \beta_j + \rho_{k(j)} + \tau_i + (\tau\beta)_{ij} + \epsilon_{ijk},

replications being nested within environments, which gives l(r−1)l(r-1) degrees of freedom for replication rather than r−1r-1.

Following the standard treatment of a series of block experiments, the environment main effect is tested against the replication-within-environment mean square, because replications are the units within which environments are compared. Treatment and the treatment-by-environment interaction are tested against the pooled error when env_effect = "fixed". When env_effect = "random" the treatment main effect is tested against the treatment-by-environment interaction instead.

Value

An object of class "cane", a list with components

Design

Name of the design analysed.

Individual_ANOVA

List of environment-wise ANOVA tables.

Location_wise

Environment-wise multiple comparisons, each computed from the error mean square of that environment.

Bartlett_Test

Bartlett's test on the error mean squares. For split plot and strip plot designs, element other_strata gives the same test for the main plot or strip error strata.

Levene_Test

Median-centred Levene (Brown-Forsythe) test.

Normality_Test

Environment-wise Shapiro-Wilk tests.

Transformation

Whether Aitken's transformation was applied, why, the environment-wise error mean squares and the ratio of the largest to the smallest.

Pooled_ANOVA

Pooled ANOVA table, including the error term used as the denominator of each F-test.

Treatments_Comparison

Pooled treatment means, groups and all pairwise differences. When a transformation was applied, means are given on the transformed scale (on which the test was performed) and the arithmetic means on the original scale are reported alongside.

GEI_Note

Advice issued when any interaction of a treatment factor with environment is significant, naming the terms concerned.

Environment_Key

Mapping of environment levels to their error mean square and error degrees of freedom.

Settings

Arguments and software versions used.

References

Aitken, A. C. (1935). On least squares and linear combination of observations. Proceedings of the Royal Society of Edinburgh, 55, 42–48. doi:10.1017/S0370164600014346

Bartlett, M. S. (1937). Properties of sufficiency and statistical tests. Proceedings of the Royal Society of London A, 160, 268–282. doi:10.1098/rspa.1937.0109

Cochran, W. G. and Cox, G. M. (1957). Experimental Designs, 2nd ed. John Wiley and Sons, New York.

Dean, A., Voss, D. and Draguljic, D. (2017). Design and Analysis of Experiments, 2nd ed. Springer, Cham. doi:10.1007/978-3-319-52250-0

Gomez, K. A. and Gomez, A. A. (1984). Statistical Procedures for Agricultural Research, 2nd ed. John Wiley and Sons, New York.

See Also

PooledCRD, PooledLSD, PooledSPD, PooledStPD

Examples

data(sugarcane)
out <- PooledRBD(sugarcane, Response = "ccsy", Location = "env",
                 Treatment = "gen", Replication = "rep",
                 alpha = 0.05, Mult_Comp_Test = 1)
out
out$Pooled_ANOVA
head(out$Treatments_Comparison$groups)

Pooled Analysis of a Series of Split Plot Designs

Description

Performs the classical pooled analysis of variance for a split plot design (SPD) repeated over several environments, with every effect tested against its proper error term.

Usage

PooledSPD(
  data,
  Response,
  Location,
  Replication,
  MainPlot,
  SubPlot,
  alpha = 0.05,
  Mult_Comp_Test = 1,
  transform = c("auto", "always", "never"),
  env_effect = c("fixed", "random")
)

Arguments

data

A data frame containing the experimental data. Rows with missing values in the variables used are dropped with a warning.

Response

Character string naming the numeric response variable.

Location

Character string naming the factor that identifies environments (locations, seasons or years).

Replication

Character string naming the replication factor.

MainPlot

Character string naming the main plot (whole plot) factor, that is the factor requiring the larger experimental units.

SubPlot

Character string naming the subplot factor.

alpha

Significance level used for the variance-homogeneity test and for the multiple comparison procedure. Default 0.05.

Mult_Comp_Test

Integer selecting the multiple comparison procedure: 1 = Tukey's honestly significant difference (HSD) test, 2 = Duncan's multiple range test (DMRT), 3 = Fisher's least significant difference (LSD) test. Option 3 makes no adjustment for multiplicity and is intended for a small number of pre-planned comparisons; a warning is issued if it is requested for more than three treatments.

transform

One of "auto" (default; transform only when the variances are judged heterogeneous at level alpha), "always" or "never".

env_effect

One of "fixed" (default) or "random". With "random" each treatment main effect is tested against its interaction with environment, and in split plot and strip plot designs the interaction of the two treatment factors is tested against the three-way interaction with environment. The pooled comparison of means then uses the same mean square and degrees of freedom as the F-test of the factor compared. With few environments that interaction has few degrees of freedom; if it has fewer than two, the Tukey and Duncan comparisons for that factor are not computed and a warning is issued.

Details

A split plot design has two error strata. Main plot effects belong to the main plot stratum and must be tested against the main plot error, Environment×Replication×MainPlotEnvironment \times Replication \times MainPlot; subplot effects and all interactions involving the subplot factor belong to the subplot stratum and are tested against the subplot (residual) error. Testing a main plot effect against the subplot error, as happens if a single-stratum model is fitted and its residual mean square is used for everything, gives an F-ratio with the wrong denominator and the wrong denominator degrees of freedom.

The pooled partition implemented here is

Environment,  Rep(Env),  A,  A×Env,  main plot error,Environment,\; Rep(Env),\; A,\; A \times Env,\; \mathrm{main\ plot\ error},

B,  B×Env,  A×B,  A×B×Env,  subplot error,B,\; B \times Env,\; A \times B,\; A \times B \times Env,\; \mathrm{subplot\ error},

where AA is the main plot factor and BB the subplot factor. With ll environments, rr replications, aa main plot levels and bb subplot levels the main plot error carries l(r−1)(a−1)l(r-1)(a-1) degrees of freedom and the subplot error la(r−1)(b−1)la(r-1)(b-1).

Mean separation is carried out in the stratum appropriate to each factor: main plot means are compared using the main plot error mean square and its degrees of freedom, subplot means using the subplot error. The stratum used is recorded in the parameters component of each comparison.

Homogeneity of error variances is assessed for both strata. The main Bartlett test, and the Aitken transformation when it is applied, use the subplot error mean square of each environment; the main plot error mean squares are tested separately and reported in Bartlett_Test$other_strata, with a note in the transformation report if they are heterogeneous.

At least two replications per environment are needed for a main plot error to exist, and three or more are strongly advised: with r=2r = 2 and a=2a = 2 the main plot error has only ll degrees of freedom and the main plot test has almost no power.

Value

An object of class "cane". The structure is as described in PooledCRD, except that Location_wise and Treatments_Comparison are each a list with components MainPlot and SubPlot, computed from the main plot and subplot error strata respectively.

References

Aitken, A. C. (1935). On least squares and linear combination of observations. Proceedings of the Royal Society of Edinburgh, 55, 42–48. doi:10.1017/S0370164600014346

Bartlett, M. S. (1937). Properties of sufficiency and statistical tests. Proceedings of the Royal Society of London A, 160, 268–282. doi:10.1098/rspa.1937.0109

Cochran, W. G. and Cox, G. M. (1957). Experimental Designs, 2nd ed. John Wiley and Sons, New York.

Dean, A., Voss, D. and Draguljic, D. (2017). Design and Analysis of Experiments, 2nd ed. Springer, Cham. doi:10.1007/978-3-319-52250-0

Gomez, K. A. and Gomez, A. A. (1984). Statistical Procedures for Agricultural Research, 2nd ed. John Wiley and Sons, New York.

See Also

PooledCRD, PooledRBD, PooledLSD, PooledStPD

Examples

data(spd_example)
out <- PooledSPD(spd_example, Response = "Yield", Location = "Location",
                 Replication = "Replication", MainPlot = "MainPlot",
                 SubPlot = "SubPlot", alpha = 0.05, Mult_Comp_Test = 1)
out
out$Pooled_ANOVA
out$Treatments_Comparison$MainPlot$parameters

Pooled Analysis of a Series of Strip Plot Designs

Description

Performs the classical pooled analysis of variance for a strip plot (split block) design repeated over several environments, with three error strata handled explicitly.

Usage

PooledStPD(
  data,
  Response,
  Location,
  Replication,
  RowFactor,
  ColumnFactor,
  alpha = 0.05,
  Mult_Comp_Test = 1,
  transform = c("auto", "always", "never"),
  env_effect = c("fixed", "random")
)

Arguments

data

A data frame containing the experimental data. Rows with missing values in the variables used are dropped with a warning.

Response

Character string naming the numeric response variable.

Location

Character string naming the factor that identifies environments (locations, seasons or years).

Replication

Character string naming the replication factor.

RowFactor

Character string naming the factor applied in horizontal strips.

ColumnFactor

Character string naming the factor applied in vertical strips.

alpha

Significance level used for the variance-homogeneity test and for the multiple comparison procedure. Default 0.05.

Mult_Comp_Test

Integer selecting the multiple comparison procedure: 1 = Tukey's honestly significant difference (HSD) test, 2 = Duncan's multiple range test (DMRT), 3 = Fisher's least significant difference (LSD) test. Option 3 makes no adjustment for multiplicity and is intended for a small number of pre-planned comparisons; a warning is issued if it is requested for more than three treatments.

transform

One of "auto" (default; transform only when the variances are judged heterogeneous at level alpha), "always" or "never".

env_effect

One of "fixed" (default) or "random". With "random" each treatment main effect is tested against its interaction with environment, and in split plot and strip plot designs the interaction of the two treatment factors is tested against the three-way interaction with environment. The pooled comparison of means then uses the same mean square and degrees of freedom as the F-test of the factor compared. With few environments that interaction has few degrees of freedom; if it has fewer than two, the Tukey and Duncan comparisons for that factor are not computed and a warning is issued.

Details

In a strip plot design the two factors are applied in perpendicular strips, which creates three error terms: a row strip error, a column strip error and an intersection error. The row factor must be tested against the row strip error Environment×Replication×RowEnvironment \times Replication \times Row, the column factor against the column strip error Environment×Replication×ColumnEnvironment \times Replication \times Column, and their interaction against the intersection (residual) error. The interaction is therefore estimated with the greatest precision, which is the characteristic merit of the design.

With ll environments, rr replications, aa row levels and bb column levels the three errors carry l(r−1)(a−1)l(r-1)(a-1), l(r−1)(b−1)l(r-1)(b-1) and l(r−1)(a−1)(b−1)l(r-1)(a-1)(b-1) degrees of freedom.

Homogeneity of error variances is assessed for all three strata: the main Bartlett test uses the intersection error mean squares, and the row strip and column strip error mean squares are tested separately and reported in Bartlett_Test$other_strata.

Aitken's transformation, when applied, divides each observation by the square root of the intersection error mean square of its own environment, matching the definition used by the other functions in the package. The lookup is by environment label, so it is unaffected by the row order of data.

Value

An object of class "cane". The structure is as described in PooledCRD, except that Location_wise and Treatments_Comparison are each a list with components RowFactor, ColumnFactor and Interaction, computed from the row strip, column strip and intersection error strata respectively.

References

Aitken, A. C. (1935). On least squares and linear combination of observations. Proceedings of the Royal Society of Edinburgh, 55, 42–48. doi:10.1017/S0370164600014346

Bartlett, M. S. (1937). Properties of sufficiency and statistical tests. Proceedings of the Royal Society of London A, 160, 268–282. doi:10.1098/rspa.1937.0109

Cochran, W. G. and Cox, G. M. (1957). Experimental Designs, 2nd ed. John Wiley and Sons, New York.

Dean, A., Voss, D. and Draguljic, D. (2017). Design and Analysis of Experiments, 2nd ed. Springer, Cham. doi:10.1007/978-3-319-52250-0

Gomez, K. A. and Gomez, A. A. (1984). Statistical Procedures for Agricultural Research, 2nd ed. John Wiley and Sons, New York.

See Also

PooledCRD, PooledRBD, PooledLSD, PooledSPD

Examples

data(stpd_example)
out <- PooledStPD(stpd_example, Response = "Yield", Location = "Location",
                  Replication = "Replication", RowFactor = "RowFactor",
                  ColumnFactor = "ColumnFactor", alpha = 0.05,
                  Mult_Comp_Test = 1)
out
out$Pooled_ANOVA

Illustrative Split Plot Design Series

Description

A balanced series of split plot experiments: two environments, four replications, two main plot levels and three subplot levels.

Usage

spd_example

Format

A data frame with 48 rows and 5 variables:

Location

Factor with 2 levels, the environment.

Replication

Factor with 4 levels.

MainPlot

Factor with 2 levels, the main plot (whole plot) factor.

SubPlot

Factor with 3 levels, the subplot factor.

Yield

Numeric response.

Details

Simulated from a known model with a genuine main plot error component in addition to the subplot error, so that the two error strata of the design are both identifiable. Four replications are used so that the main plot error has adequate degrees of freedom.

Examples

data(spd_example)
with(spd_example, table(MainPlot, SubPlot, Location))

Illustrative Strip Plot Design Series

Description

A balanced series of strip plot (split block) experiments: two environments, four replications, two row strip levels and three column strip levels.

Usage

stpd_example

Format

A data frame with 48 rows and 5 variables:

Location

Factor with 2 levels, the environment.

Replication

Factor with 4 levels.

RowFactor

Factor with 2 levels, applied in horizontal strips.

ColumnFactor

Factor with 3 levels, applied in vertical strips.

Yield

Numeric response.

Details

Simulated from a known model containing separate row strip, column strip and intersection error components, so that all three error strata of the design are identifiable.

Examples

data(stpd_example)
with(stpd_example, table(RowFactor, ColumnFactor, Location))

Sugarcane Multi-Environment Trial (Commercial Cane Sugar Yield)

Description

Commercial cane sugar yield of 18 sugarcane (Saccharum spp. hybrids) genotypes evaluated in a randomised block design at two locations in peninsular India over three crop cycles, giving six environments.

Usage

sugarcane

Format

A data frame with 216 rows and 6 variables:

env

Factor with 6 levels, the environment (location-by-crop-cycle).

loc

Factor with 2 levels, SGA and TCSM.

crop

Factor with 3 levels, IP, IIP and R.

rep

Factor with 2 levels, the replication (block) within environment.

gen

Factor with 18 levels, the genotype.

ccsy

Numeric, commercial cane sugar yield in t/ha.

Details

The trials were conducted by the ICAR-Sugarcane Breeding Institute at Sakthi Sugars, Sivaganga (SGA) and Tiruttani Cooperative Sugar Mills, Thiruvalangadu (TCSM), both in Tamil Nadu, India. The three crop cycles are plant I (IP), plant II (IIP) and ratoon (R). The six environments are the location-by-cycle combinations, labelled SGA-IP, SGA-IIP, SGA-R, TCSM-IP, TCSM-IIP and TCSM-R.

Two replications are distributed. A third column of values present in an earlier working version of these data was found, on audit, to be identically the arithmetic mean of the two observed replicates in the SGA-R, TCSM-IIP and TCSM-R trials, for every one of the 18 genotypes. Such a value is a derived quantity, not an independently randomised experimental unit: including it leaves the error sum of squares of those environments unchanged while doubling the error degrees of freedom, which halves the error mean square; because the genotype means are unchanged, the genotype sum of squares is at the same time multiplied by three halves, so the genotype F-ratio is inflated by exactly three. Only the two genuine replicates are therefore included, giving a fully balanced series of six two-replicate randomised block experiments.

Source

ICAR-Sugarcane Breeding Institute, Coimbatore, Tamil Nadu, India. Institute Plan Project P1-15/4-1(v).

Examples

data(sugarcane)
str(sugarcane)
with(sugarcane, table(env, rep))
round(tapply(sugarcane$ccsy, sugarcane$env, mean), 3)