GGEPlot: GGE biplots with 'ggplot2'

Description Usage Arguments Value References Examples

Description

Produces the GGE biplot as an object of class 'ggplot' from a model produced by a call to either GGEModel or gge. Nearly all stylistic attributes of output can either be customised within the function or disabled so that the user can customise output to their own liking.

Usage

1
2
3
4
5
6
GGEPlot(GGEModel, type = 1, d1 = 1, d2 = 2, selectedE = NA,
  selectedG = NA, selectedG1 = NA, selectedG2 = NA,
  colGen = "forestgreen", colEnv = "blue", colSegment = "red",
  colHull = "black", sizeGen = 4, sizeEnv = 4, largeSize = 4.5,
  axis_expand = 1.2, axislabels = TRUE, axes = TRUE, limits = TRUE,
  titles = TRUE, footnote = TRUE)

Arguments

GGEModel

An object of class GGEModel or gge

type

type of biplot to produce.

  1. Basic biplot.

  2. Examine environment. See ExamineEnv

  3. Examine genotype. See ExamineGen

  4. Relationship among environments. See EnvRelationship

  5. Compare two genotypes. See CompareGens

  6. Which won where/what. See WhichWon

  7. Discrimination vs. representativeness. See DiscRep

  8. Ranking environments. See RankEnv

  9. Mean vs. stability. See MeanStability

  10. Ranking gentoypes See RankGen

d1

PCA component to plot on x axis. Defaults to 1

d2

PCA component to plot on y axis. Defaults to 2

selectedE

name of the environment to examine when type=2. Must be a string which matches an environment label

selectedG

name of the genotype to examine when type=3. Must be a string which matches a genotype label

selectedG1

name of a genotype to compare when type=5. Must be a string which matches a genotype label

selectedG2

name of a genotype to compare when type=5. Must be a string which matches a genotype label and not equal to selectedG1

colGen

colour for genotype attributes on biplot. Defaults to "forestgreen"

colEnv

colour for environment attributes on biplot. Defaults to "blue"

colSegment

colour for segment or circle lines. Defaults to "red"

colHull

colour for hull when type=6. Defaults to "black"

sizeGen

text size for genotype labels. Defaults to 4

sizeEnv

text size for environment labels. Defaults to 4

largeSize

text size to use for larger labels where type=5, used for the two selected genotypes, and where type=6, used for the outermost genotypes. Defaults to 4.5

axis_expand

multiplication factor to expand the axis limits by to enable fitting of labels. Defaults to 1.2

axislabels

logical. If TRUE then include automatically generated labels for axes

axes

logical. If TRUE then include x and y axes going through the origin

limits

logical. If TRUE then automatically rescale axes

titles

logical. If TRUE then include automatically generated titles

footnote

logical. If TRUE then include automatically generated footbote

Value

A biplot of class ggplot

References

Yan W, Kang M (2003). GGE Biplot Analysis: A Graphical Tool for Breeders, Geneticists, and Agronomists. CRC Press.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
library(GGEBiplotGUI)
data(Ontario)
GGE1<-GGEModel(Ontario)
GGEPlot(GGE1)

#using 'gge' instead

library(gge)
GGE2<-gge(as.matrix(Ontario))
GGEPlot(GGE2)
   

Example output

Loading required package: rgl
Loading required package: tcltk
Loading required package: tkrplot
Warning messages:
1: In rgl.init(initValue, onlyNULL) : RGL: unable to open X11 display
2: 'rgl_init' failed, running with rgl.useNULL = TRUE 
3: .onUnload failed in unloadNamespace() for 'rgl', details:
  call: fun(...)
  error: object 'rgl_quit' not found 
4: no DISPLAY variable so Tk is not available 
5: loading Rplot failed 

GGEBiplots documentation built on May 2, 2019, 6:03 a.m.