Learn R Programming

agridat (version 1.12)

gge: GGE biplots

Description

Fit a GGE (genotype + genotype * environment) model and display the results.

Usage

gge(x, ...)

# S3 method for formula gge(formula, data = NULL, gen.group = NULL, env.group = NULL, ...)

# S3 method for matrix gge(x, center = TRUE, scale = TRUE, gen.group=NULL, env.group = NULL, comps=c(1,2), method = "svd", ...)

# S3 method for gge plot(x, title = substitute(x), ...)

# S3 method for gge biplot(x, title = substitute(x), subtitle = "", cex.gen = 0.6, cex.env = 0.5, col.gen = "darkgreen", col.env="orange3", pch.gen=1, lab.env = TRUE, comps = 1:2, flip = "auto", res.vec=TRUE, ...)

Arguments

x

A matrix or data.frame.

formula

A formula

data

Data frame

Other arguments

title

title

center

If TRUE, center values for each environment

scale

If TRUE, scale values for each environment

subtitle

subtitle

gen.group

genotype group

env.group

env group

cex.gen

character expansion for genotypes

cex.env

character expansion for environments

col.gen

color for genotypes

col.env

color for envts

pch.gen

plot character for genotypes

lab.env

label envts

comps

comps

flip

If "auto" then each axis is flipped so that the genotype ordinate is positively correlated with genotype means. Can also be a vector like c(TRUE,FALSE) for manual control.

res.vec

If TRUE, for each group, draw residual vectors from the mean of the locs to the individual locs

method

method used to find principal component directions

Value

A list of class gge containing:

method

center

Data centered?

scale

Data scaled?

gen.group

This is only used for plotting. If not NULL, this specifies a classification of genotypes into groups.

env.group

If not NULL, this specifies a classification of environments into groups. When using the formula method, then envGroup is the name of a column in the data. When using the matrix method, then envGroup must be a vector the same length as the number of columns in data, the contents of the vector contain the grouping information.

Details

If there is replication in G*E, then the replications are averaged together before constructing the biplot.

The singular value decomposition of x is used to calculate the principal components for the biplot. Missing values are NOT allowed.

The NIPALS algorithm can be used when there are missing data.

The argument 'method' can be either 'svd' for complete-data, or 'nipals' for missing-data.

References

Jean-Louis Laffont, Kevin Wright and Mohamed Hanafi (2013). Genotype + Genotype x Block of Environments (GGB) Biplots. Crop Science, 53, 2332-2341. https://www.crops.org/publications/cs/abstracts/53/6/2332.

Kroonenberg, Pieter M. (1997) Introduction to Biplots for GxE Tables, Research Report 51, Centre for Statistics, The University of Queensland, Brisbane, Australia. http://three-mode.leidenuniv.nl/document/biplot.pdf

Yan, W. and Kang, M.S. (2003) GGE Biplot Analysis. CRC Press.

See Also

The 'agricolae' package has functions for AMMI biplots.

Examples

Run this code
# NOT RUN {
# Example 1.  Data is a data.frame in 'matrix' format
B <- matrix(c(50, 67, 90, 98, 120,
              55, 71, 93, 102, 129,
              65, 76, 95, 105, 134,
              50, 80, 102, 130, 138,
              60, 82, 97, 135, 151,
              65, 89, 106, 137, 153,
              75, 95, 117, 133, 155), ncol=5, byrow=TRUE)
rownames(B) <- c("G1","G2","G3","G4","G5","G6","G7")
colnames(B) <- c("E1","E2","E3","E4","E5")

m1 = gge(B)
plot(m1)
biplot(m1, title="Example biplot")

# crossa.wheat biplot

# Specify env.group as column in data frame
data(crossa.wheat)
dat2 <- crossa.wheat
dat2$eg <- ifelse(is.element(dat2$loc,
c("KN","NB","PA","BJ","IL","TC", "JM","PI","AS","ID","SC","SS",
"SJ","MS","MG","MM")), "Grp1", "Grp2")
m4 <- gge(yield~gen*loc, dat2, env.group=eg, scale=FALSE)
biplot(m4, lab.env=TRUE, title="crossa.wheat")

# }

Run the code above in your browser using DataLab