Type: Package
Title: Comprehensive Groups of Experiments Analysis for Numerous Environments
Version: 0.1.1
Maintainer: Vinayaka <vinayaka.b3vs@gmail.com>
Description: In many cases, experiments must be repeated across multiple seasons or locations to ensure applicability of findings. A single experiment conducted in one location and season may yield limited conclusions, as results can vary under different environmental conditions. In agricultural research, treatment × location and treatment × season interactions play a crucial role. Analyzing a series of experiments across diverse conditions allows for more generalized and reliable recommendations. The 'CANE' package facilitates the pooled analysis of experiments conducted over multiple years, seasons, or locations. It is designed to assess treatment interactions with environmental factors (such as location and season) using various experimental designs. The package supports pooled analysis of variance (ANOVA) for the following designs: (1) 'PooledCRD()': completely randomized design; (2) 'PooledRBD()': randomized block design; (3) 'PooledLSD()': Latin square design; (4) 'PooledSPD()': split plot design; and (5) 'PooledStPD()': strip plot design. Each function provides the following outputs: (i) Individual ANOVA tables based on independent analysis for each location or year; (ii) Testing of homogeneity of error variances among distinct locations using Bartlett’s Chi-Square test; (iii) If Bartlett’s test is significant, 'Aitken’s' transformation, defined as the ratio of the response to the square root of the error mean square, is applied to the response variable; otherwise, the data is used as is; (iv) Combined analysis to obtain a pooled ANOVA table; (v) Multiple comparison tests, including Tukey's honestly significant difference (Tukey's HSD) test, Duncan’s multiple range test (DMRT), and the least significant difference (LSD) test, for treatment comparisons. The statistical theory and steps of analysis of these designs are available in Dean et al. (2017)<doi:10.1007/978-3-319-52250-0> and Ruíz et al. (2024)<doi:10.1007/978-3-031-65575-3>. By broadening the scope of experimental conclusions, 'CANE' enables researchers to derive robust, widely applicable recommendations. This package is particularly valuable in agricultural research, where accounting for treatment × location and treatment × season interactions is essential for ensuring the validity of findings across multiple settings.
Imports: agricolae, dplyr, emmeans, stats
License: GPL-3
Encoding: UTF-8
Depends: R (≥ 4.0.0)
RoxygenNote: 7.3.2
NeedsCompilation: no
Packaged: 2025-03-20 08:44:51 UTC; DELL
Author: Vinayaka ORCID iD [aut, cre], T. Lakshmi Pathy ORCID iD [aut, ctb], K. Gopalareddy ORCID iD [aut, ctb], Shweta Kumari ORCID iD [aut, ctb], P. Murali ORCID iD [aut, ctb], P. Govindaraj [aut, ctb], P. Rama Chandra Prasad ORCID iD [aut, ctb], L.N. Vinaykumar [aut, ctb]
Repository: CRAN
Date/Publication: 2025-03-20 13:50:13 UTC

Pooled Completely Randomized Design Analysis

Description

This function performs pooled analysis of variance (ANOVA) using the completely randomized design (CRD) for multiple locations or years. For more details see Montgomery (2017), Dean et al. (2017)<doi:10.1007/978-3-319-52250-0> and Ruíz et al. (2024)<doi:10.1007/978-3-031-65575-3>.

Usage

PooledCRD(data, Response, Location, Treatment, alpha, Mult_Comp_Test)

Arguments

data

A data frame containing the experimental data.

Response

A numeric variable representing the dependent variable (response).

Location

A factor indicating different locations or years.

Treatment

A factor indicating the different treatments applied.

alpha

A numeric value specifying the significance level for Bartlett’s test.

Mult_Comp_Test

An integer specifying the type of multiple comparison test:

  • 1 = Tukey's honestly significant difference (Tukey's HSD) test

  • 2 = Duncan's multiple range test (DMRT)

  • 3 = least significant difference (LSD) test

Value

A list containing the following components:

References

Dean A, Voss D, Draguljic D (2017)<doi:10.1007/978-3-319-52250-0>.

Montgomery DC (2017). Design and Analysis of Experiments. John wiley & sons.

Ruíz JS, López OAM, Crossa J (2024)<doi:10.1007/978-3-031-65575-3>.

Examples

# Creating a sample dataset for Pooled Completely Randomized Design (CRD)
df <- data.frame(
  Loc = factor(rep(c("L1", "L2"), each = 9)),  # Locations
  Treatment = factor(rep(c("T1", "T2", "T3"), times = 6)),  # Treatments
  Yield = c(18, 7, 11, 10, 19, 12, 15, 8, 13, 
            18, 5, 11, 7, 19, 21, 22, 9, 14)  # Yield values
)

# Running PooledCRD function on the dataset
out <- PooledCRD(df, "Yield", "Loc", "Treatment", 0.05, 1)

# Print results
print(out)

Pooled Latin Square Design Analysis

Description

This function performs pooled analysis of variance (ANOVA) using the Latin square design for multiple locations or years. For more details see Montgomery (2017), Dean et al. (2017)<doi:10.1007/978-3-319-52250-0> and Ruíz et al. (2024)<doi:10.1007/978-3-031-65575-3>.

Usage

PooledLSD(
  data,
  Response,
  Location,
  Treatment,
  Row,
  Column,
  alpha,
  Mult_Comp_Test
)

Arguments

data

A data frame containing the experimental data.

Response

A numeric variable representing the dependent variable (response).

Location

A factor indicating different locations or years.

Treatment

A factor indicating the different treatments applied.

Row

A factor indicating rows.

Column

A factor indicating columns.

alpha

A numeric value specifying the significance level for Bartlett’s test.

Mult_Comp_Test

An integer specifying the type of multiple comparison test:

  • 1 = Tukey's honestly significant difference (Tukey's HSD) test

  • 2 = Duncan's multiple range test (DMRT)

  • 3 = least significant difference (LSD) test

Value

A list containing the following components:

References

Dean A, Voss D, Draguljic D (2017)<doi:10.1007/978-3-319-52250-0>.

Montgomery DC (2017). Design and Analysis of Experiments. John wiley & sons.

Ruíz JS, López OAM, Crossa J (2024)<doi:10.1007/978-3-031-65575-3>.

Examples

# Creating a sample dataset for Pooled Latin Square Design (LSD)
df <- data.frame(
  Location = factor(c(rep("Agra", 16), rep("Bihar", 16))),  # Locations
  Treatment = factor(c(4, 2, 3, 1, 3, 1, 4, 2, 1, 4, 2, 3, 2, 3, 1, 4,
  4, 2, 3, 1, 3, 1, 4, 2, 1, 4, 2, 3, 2, 3, 1, 4)),  # Treatments
  Row = factor(rep(1:4, each = 4, times = 2)),  # Row factor
  Column = factor(rep(1:4, times = 8)),  # Column factor
  Yield = c(29.1, 18.9, 29.4, 5.7, 16.4, 10.2, 21.2, 19.1, 5.4, 38.8, 24, 37, 
            24.9, 41.7, 9.5, 28.9, 13, 27, 7, 24, 10, 13, 41, 39, 42, 26, 19, 20, 
            20, 35, 8, 38)  # Yield values
)

# Running PooledLSD function on the dataset
out <- PooledLSD(df, "Yield", "Location", "Treatment", "Row", "Column", 0.05, 1)

# Print results
print(out)

Pooled Randomized Block Design Analysis

Description

This function performs pooled analysis of variance (ANOVA) using the randomized block design (RBD) for multiple locations or years. For more details see Montgomery (2017), Dean et al. (2017)<doi:10.1007/978-3-319-52250-0> and Ruíz et al. (2024)<doi:10.1007/978-3-031-65575-3>.

Usage

PooledRBD(
  data,
  Response,
  Location,
  Treatment,
  Replication,
  alpha,
  Mult_Comp_Test
)

Arguments

data

A data frame containing the experimental data.

Response

A numeric variable representing the dependent variable (response).

Location

A factor indicating different locations or years.

Treatment

A factor indicating the different treatments applied.

Replication

A factor indicating replications of treatments.

alpha

A numeric value specifying the significance level for Bartlett’s test.

Mult_Comp_Test

An integer specifying the type of multiple comparison test:

  • 1 = Tukey's honestly significant difference (Tukey's HSD) test

  • 2 = Duncan's multiple range test (DMRT)

  • 3 = least significant difference (LSD) test

Value

A list containing the following components:

References

Dean A, Voss D, Draguljic D (2017)<doi:10.1007/978-3-319-52250-0>.

Montgomery DC (2017). Design and Analysis of Experiments. John wiley & sons.

Ruíz JS, López OAM, Crossa J (2024)<doi:10.1007/978-3-031-65575-3>.

Examples

# Creating a sample dataset for Pooled Randomized Block Design (RBD)
df <- data.frame(
  Loc = factor(rep(c("L1", "L2"), each = 9)),  # Locations
  Rep = factor(rep(c("R1", "R2", "R3"), each = 3, times = 2)),  # Replications
  Treatment = factor(rep(c("T1", "T2", "T3"), times = 6)),  # Treatments
  Yield = c(18, 7, 11, 10, 19, 12, 15, 8, 13, 
            18, 5, 11, 7, 19, 21, 22, 9, 14)  # Yield values
)

# Running PooledRBD function on the dataset
out <- PooledRBD(df, "Yield", "Loc", "Treatment", "Rep", 0.05, 1)

# Print results
print(out)

Pooled Split Plot Design Analysis

Description

This function conducts a pooled analysis of variance (ANOVA) using the split plot design (SPD) for data collected across multiple locations or years. In this design, subplot effects are estimated with greater precision. For more details see Dean et al. (2017)<doi:10.1007/978-3-319-52250-0> and Ruíz et al. (2024)<doi:10.1007/978-3-031-65575-3>.

Usage

PooledSPD(
  data,
  Response,
  Location,
  Replication,
  MainPlot,
  SubPlot,
  alpha,
  Mult_Comp_Test
)

Arguments

data

A data frame containing the experimental data.

Response

A numeric variable representing the dependent variable (response).

Location

A factor indicating different locations or years.

Replication

A factor indicating replications.

MainPlot

A factor which require larger plot sizes.

SubPlot

A factor which require smaller plot sizes.

alpha

A numeric value specifying the significance level for Bartlett’s test.

Mult_Comp_Test

An integer specifying the type of multiple comparison test:

  • 1 = Tukey's honestly significant difference (Tukey's HSD) test

  • 2 = Duncan's multiple range test (DMRT)

  • 3 = least significant difference (LSD) test

Value

A list containing the following components:

References

Dean A, Voss D, Draguljic D (2017)<doi:10.1007/978-3-319-52250-0>.

Ruíz JS, López OAM, Crossa J (2024)<doi:10.1007/978-3-031-65575-3>.

Examples

# Creating a sample dataset for Pooled Split Plot Design (SPD)
df <- data.frame(
  Location = factor(rep(c("Londan", "Agumbe"), each = 12)),  # Locations
  Replication = factor(rep(c(1, 2), each = 6, times = 2)),  # Replications
  MainPlot = factor(rep(c(1, 2), each = 3, times = 4)),  # Main plot factor
  SubPlot = factor(rep(1:3, times = 8)),  # Sub plot factor
  Yield = c(4940, 4810, 5150, 4900, 4920, 5070, 
            4830, 5110, 4920, 5020, 5110, 5230,
            4964, 4997, 5011, 5102, 4858, 4888, 
            5100, 5165, 4965, 5113, 5086, 5176)  # Yield values
)

# Running PooledSPD function on the dataset
out <- PooledSPD(df, "Yield", "Location", "Replication", "MainPlot", "SubPlot", 0.05, 1)

# Print results
print(out)

Pooled Strip Plot Design Analysis

Description

This function conducts a pooled analysis of variance (ANOVA) using the strip plot design (StPD) for data collected across multiple locations or years. In this design, the interaction between factors (RowFactor and ColumnFactor) is estimated with higher precision. For more details see Dean et al. (2017)<doi:10.1007/978-3-319-52250-0> and Ruíz et al. (2024)<doi:10.1007/978-3-031-65575-3>.

Usage

PooledStPD(
  data,
  Response,
  Location,
  Replication,
  RowFactor,
  ColumnFactor,
  alpha,
  Mult_Comp_Test
)

Arguments

data

A data frame containing the experimental data.

Response

A numeric variable representing the dependent variable (response).

Location

A factor indicating different locations or years.

Replication

A factor indicating replications.

RowFactor

A factor used for horizontal strips.

ColumnFactor

A factor used for vertical strips.

alpha

A numeric value specifying the significance level for Bartlett’s test.

Mult_Comp_Test

An integer specifying the type of multiple comparison test:

  • 1 = Tukey's honestly significant difference (Tukey's HSD) test

  • 2 = Duncan's multiple range test (DMRT)

  • 3 = least significant difference (LSD) test

Value

A list containing the following components:

References

Dean A, Voss D, Draguljic D (2017)<doi:10.1007/978-3-319-52250-0>.

Ruíz JS, López OAM, Crossa J (2024)<doi:10.1007/978-3-031-65575-3>.

Examples

# Creating a sample dataset for Pooled Strip Plot Design (StPD)
df <- data.frame(
  Location = factor(rep(c("Londan", "Agumbe"), each = 12)),  # Locations
  Replication = factor(rep(c(1, 2), each = 6, times = 2)),  # Replications
  RowFactor = factor(rep(c(1, 2), each = 3, times = 4)),  # Row factor
  ColumnFactor = factor(rep(1:3, times = 8)),  # Column factor
  Yield = c(4940, 4810, 5150, 4900, 4920, 5070, 
            4830, 5110, 4920, 5020, 5110, 5230,
            4964, 4997, 5011, 5102, 4858, 4888, 
            5100, 5165, 4965, 5113, 5086, 5176)  # Yield values
)

# Running PooledStPD function on the dataset
out <- PooledStPD(df, "Yield", "Location", "Replication", "RowFactor", "ColumnFactor", 0.05, 1)

# Print results
print(out)