fa_summary {agriutilities}R Documentation

Factor Analytic Summary

Description

Factor Analytic Summary

Usage

fa_summary(
  model = NULL,
  trial = "trial",
  genotype = "genotype",
  BLUEs_trial = NULL,
  mult_fa1 = -1,
  mult_fa2 = 1,
  filter_score = 1.5,
  k_biplot = 1,
  size_label_var = 2,
  alpha_label_var = 0.2,
  size_label_ind = 2,
  alpha_label_ind = 0.8,
  size_arrow = 0.2,
  alpha_arrow = 0.2,
  base_size = 12
)

Arguments

model

Factor Analytic Model (ASReml object)

trial

A character string indicating the column in data that contains trials.

genotype

A character string indicating the column in data that contains genotypes.

BLUEs_trial

A data.frame containing BLUEs for each trial.

mult_fa1

A constant to multiply the first loading. Must be 1 or -1. (-1 by default)

mult_fa2

A constant to multiply the second loading. Must be 1 or -1. (1 by default)

filter_score

A numeric value to filter genotypes by the distance from the origin.

k_biplot

A numeric value to multiply the scores in the biplot.

size_label_var

A numeric value to define the label size for the variables.

alpha_label_var

A numeric value between (0,1) to define the label for the variables.

size_label_ind

A numeric value to define the label size for the individuals.

alpha_label_ind

A numeric value between (0,1) to define the label for the individuals.

size_arrow

A numeric value to define the arrow size.

alpha_arrow

A numeric value between (0,1) to define the arrow.

base_size

A numeric value to define the base size.

Value

An object with a list of:

loadings

A data.frame containing the first and second loading for each trial.

loading_star

A data.frame containing the first and second loading rotated for each trial.

Gvar

A matrix of the estimated variance-covariance between trials.

Cmat

A matrix of the correlation between trials.

summary_loading

A data.frame containing a summary of the loadings.

paf_site

A data.frame containing the percentage of variance explained for each component and for each trial.

var_tot

A numeric value of the total variance.

scores

A data.frame containing the scores for each genotype.

plots

A list with different plots. Includes a plot for the loadings, biplot, biplot_scaled and loadings_c.

Examples

## Not run: 
library(agridat)
library(agriutilities)
data(besag.met)
dat <- besag.met
results <- check_design_met(
  data = dat,
  genotype = "gen",
  trial = "county",
  traits = c("yield"),
  rep = "rep",
  block = "block",
  col = "col",
  row = "row"
)
out <- single_trial_analysis(results, progress = FALSE)
met_results <- met_analysis(out, vcov = "fa2", progress = FALSE)

pp <- met_results$trial_effects
model <- met_results$met_models$yield
fa_summary(
  model = model,
  trial = "trial",
  genotype = "genotype",
  BLUEs_trial = pp,
  mult_fa1 = -1,
  mult_fa2 = -1,
  filter_score = 1,
  k_biplot = 10,
  size_label_var = 3,
  alpha_label_var = 0.5,
  size_label_ind = 3,
  alpha_label_ind = 0.8,
  size_arrow = 0.2,
  alpha_arrow = 0.1
)

## End(Not run)

[Package agriutilities version 1.2.0 Index]