ge_means: Genotype-environment means

View source: R/ge_means.R

ge_meansR Documentation

Genotype-environment means

Description

[Stable]

Computes genotype-environment interaction means

Usage

ge_means(.data, env, gen, resp)

Arguments

.data

The dataset containing the columns related to Environments, Genotypes, and the response variable(s).

env

The name of the column that contains the levels of the environments.

gen

The name of the column that contains the levels of the genotypes.

resp

The response variable(s). To analyze multiple variables at once, a vector of variables may be used. For example resp = c(var1, var2, var3). Select helpers are also allowed.

Value

A list where each element is the result for one variable containing:

  • ge_means: A two-way table with the means for genotypes (rows) and environments (columns).

  • gen_means: A tibble with the means for genotypes.

  • env_means: A tibble with the means for environments.

Author(s)

Tiago Olivoto tiagoolivoto@gmail.com

Examples


library(metan)
means_ge <- ge_means(data_ge, ENV, GEN, resp = everything())

# Genotype-environment interaction means
get_model_data(means_ge)

# Environment means
get_model_data(means_ge, what = "env_means")

# Genotype means
get_model_data(means_ge, what = "gen_means")




metan documentation built on March 7, 2023, 5:34 p.m.