Description Usage Arguments Details Examples
Shows performance of a trait or index for all varties separately in each environment. Data for each environment are displayed as violin plots.
1 2 | gg_env_plot(atable, genotypes = unique(as.character(atable$Genotype))[1:10],
trait = names(atable)[ncol(atable)])
|
atable |
a dataframe containing at least three columns: Genotype, Locality, [Trait] in this order. |
genotypes |
a subset of up to 10 genotypes that will be highlighted through lines. |
trait |
the trait (or index) to be shown |
One or more (up to 10) genotypes can be highlighted, that is they will be displayed in differntly colored dots and are connected through lines which are also correspondingly colored.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | # Get sample data
library(agricolae)
data(plrv)
library(fbmet)
# enable easy summaries
#library(magrittr)
library(dplyr)
atable <- plrv %>% group_by(Genotype, Locality) %>% summarise(Yield = mean(Yield))
if(interactive()){
gg_env_plot(atable)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.