PCA_RDA_graphics {GABB}R Documentation

PCA_RDA_graphics function This function facilitate the user creation of PCA (! from FactoMineR package !) enhanced graphics with multiple options. Individuals and variables graphics are possible. With or without variable cor, cos, contrib.. correlation to dimensions. RDA outputs are displayable as table under graphics.

Description

PCA_RDA_graphics function This function facilitate the user creation of PCA (! from FactoMineR package !) enhanced graphics with multiple options. Individuals and variables graphics are possible. With or without variable cor, cos, contrib.. correlation to dimensions. RDA outputs are displayable as table under graphics.

Usage

PCA_RDA_graphics(
  complete.data.set,
  factor.names,
  sample.column,
  PCA.object,
  Var.quanti.supp,
  Display.quanti.supp,
  Dim.a,
  Dim.b,
  Barycenter,
  Segments,
  Barycenter.min.size,
  Ind.min.size,
  Segment.line.type,
  Segment.line.size,
  Segment.line.col,
  Ellipse.IC,
  IC.x,
  Ellipse.sd,
  sd.x,
  Ellipse.transparency,
  Barycenter.Ellipse.Fac1,
  Barycenter.Ellipse.Fac2,
  Barycenter.Ellipse.Fac3,
  factor.colors,
  color.palette,
  factor.shapes,
  factor.sizes,
  Barycenter.factor.col,
  Barycenter.factor.size,
  Barycenter.factor.shape,
  factor.col.border.ellipse,
  ellipse.line.type,
  Var.circle,
  Var.circle.size,
  Var.selected,
  Var.label.size,
  Var.label.repel,
  col.arrow.var.PCA,
  col.text.var.PCA,
  col.arrow.var.supp.PCA,
  col.circle.var.PCA,
  Biplot.PCA,
  width.PCA.ind.graph,
  width.PCA.var.graph,
  width.heat.map.graph,
  Spacing.HM.circle,
  Heat.map.graph,
  Type.heat.map.graph,
  var.parameter.heat.map,
  Dims.heat.map,
  Display.cell.values.heat.map,
  Top.var.heat.map.Dim.a,
  Top.var.heat.map.Dim.b,
  Multi.dim.combination,
  width.cell.heat.map,
  height.cell.heat.map,
  Cluster.col.heat.map,
  Cluster.row.heat.map,
  RDA.object,
  nbperms,
  RDA.table.graph,
  RDA.table.graph.height,
  Size.RDA.table.graph,
  Get.generated.data.frame
)

Arguments

complete.data.set

Original complete data set used for the PCA, with quantitative and qualitative/factor columns.

factor.names

Character vector regrouping names of considered factor variables of PCA.

sample.column

Numeric or name (character) of the individual sample column. Default is data frame row names.

PCA.object

The PCA object, built from package FactoMineR. PCA.object <- FactoMineR::PCA(mtcars_quant, scale.unit = T, ncp = 5, graph = F).

Var.quanti.supp

Character vector of column name of supplementary quantitative variables for PCA.

Display.quanti.supp

TRUE or FALSE. Display supplementary quantitative variable on PCA var and Heat map graphs.

Dim.a

Numeric value (1 ; 2 ...) of the first PCA dimension selected for graphic outputs.

Dim.b

Numeric value (1 ; 2 ...) of the first PCA dimension selected for graphic outputs.

Barycenter

TRUE or FALSE. TRUE : Calculate and Display the barycenter of individuals for Barycenter.Ellipse.Fac1 and/or .2 and/or .3.

Segments

TRUE or FALSE. TRUE : Display the linking segments between individuals and barycenters.

Barycenter.min.size

Numeric. Minimum size of barycenter point projections. Ignore if Barycenter = FALSE.

Ind.min.size

Numeric. Minimum size of individuals point projections.

Segment.line.type

Numeric. Type of segment lines (see ggplot2 line type). Ignore if Segments = FALSE.

Segment.line.size

Numeric. Minimum size of segment lines. Ignore if Segments = FALSE.

Segment.line.col

Character. Set the color of segments. Default = azure4.

Ellipse.IC

TRUE or FALSE. TRUE : Calculate and Display Ellipse of mean confidence interval of individuals for Barycenter.Ellipse.Fac1 and/or .2 and/or .3. Default is 95% mean confidence interval.

IC.x

0 to 100. Set the value of mean confidence interval of Ellipse.IC parameter. Default is 95.

Ellipse.sd

TRUE or FALSE. TRUE : Calculate and Display Ellipse of mean standard deviation of individuals for Barycenter.Ellipse.Fac1 and/or .2 and/or .3. Default is 95% mean confidence interval.

sd.x

Numeric. Set the value of the multiplication factor of sd (x*sd) for Ellipse.sd parameter. Default is 1.

Ellipse.transparency

Set the transparency level of the ellipse, ranging from 0 to 1. Default is 0.1.

Barycenter.Ellipse.Fac1

Character. Name of 1st factor/data frame column for Barycenter / Ellipses calculation.

Barycenter.Ellipse.Fac2

Character. Name of 2nd factor/data frame column for Barycenter / Ellipses calculation.

Barycenter.Ellipse.Fac3

Character. Name of 3rd factor/data frame column for Barycenter / Ellipses calculation.

factor.colors

Character. Name of the factor/column considered for individuals colors.

color.palette

Vector of characters of desired colors.

factor.shapes

Character. Name of the factor/column considered for individual and barycenter shapes.

factor.sizes

Character. Name of the factor/column considered for individual and barycenter colors.

Barycenter.factor.col

Character. Name of the factor/column considered for barycenter colors.

Barycenter.factor.size

Character. Name of the factor/column considered for barycenter size.

Barycenter.factor.shape

Character. Name of the factor/column considered for barycenter shape.

factor.col.border.ellipse

Character. Name of the factor/column considered for ellipse border colors.

ellipse.line.type

Numeric. R line type for ellipse borders.

Var.circle

TRUE or FALSE. TRUE = Display the PCA variable circle projection.

Var.circle.size

Numeric. Value for increasing the size of Var.circle graphic.

Var.selected

Character vector of selected variables for the PCA plot. Default = all variables.

Var.label.size

Numeric. Value for increasing the size of Var.circle graphic labels.

Var.label.repel

TRUE or FALSE. For PCA variables graphic, force variable labels to repel.

col.arrow.var.PCA

Character. Set the color of arrows for PCA variable plot. Default = gray20.

col.text.var.PCA

Character. Set the color of text for PCA variable plot. Default = gray20.

col.arrow.var.supp.PCA

Character. Set the color of arrows and text for PCA supplementary variable plot. Default = cadetblue.

col.circle.var.PCA

Character. Set the color of the PCA variable circle. Default = gray20.

Biplot.PCA

TRUE or FALSE. TRUE = Biplot of PCA individuals and variables graphics. Default is set to FALSE.

width.PCA.ind.graph

Numeric. Width ratio for PCA individuals graphic.

width.PCA.var.graph

Numeric. Width ratio for PCA variables graphic.

width.heat.map.graph

Numeric. Width ratio for Heat map variables graphic.

Spacing.HM.circle

Numeric. Width ratio for spacing x axis of circle heat map variables graphic. Default is 0.06.

Heat.map.graph

TRUE or FALSE. TRUE = Display the heat map of variable X parameter correlation to dimension.

Type.heat.map.graph

Character. Define the type of heat map to display : "square" or "circle". Default = "square".

var.parameter.heat.map

Character. Parameter selected for the heat map correlation of Variable parameter to dimensions. values : "cor", "cos2", "coor","contrib". Default = "cor".

Dims.heat.map

Numeric. Numeric vector c(1,2) of dimensions considered for the variable parameter correlation.

Display.cell.values.heat.map

TRUE or FALSE. TRUE = Display the rounded value of correlations within heat map cells.

Top.var.heat.map.Dim.a

Numeric. Number of variables to plot in heat maps and PCA variable projection for Dim a. Default = all.

Top.var.heat.map.Dim.b

Numeric. Number of variables to plot in heat maps and PCA variable projection for Dim b. Default = all.

Multi.dim.combination

TRUE or FALSE. TRUE = display 10 plots of PCA ind and variables dims combination (1,2 ; 1,3...).

width.cell.heat.map

Numeric. Width for Heat map cells. Default set to default pheat.map.

height.cell.heat.map

Numeric. Width for Heat map cells. Default set to default pheat.map.

Cluster.col.heat.map

TRUE or FALSE. TRUE = cluster heat.map columns / dimensions.

Cluster.row.heat.map

TRUE or FALSE. TRUE = cluster heat.map rows / quantitative variables.

RDA.object

The RDA object, built from package vegan. RDA.object <- vegan::rda(mtcars_quant, scale.unit = T, ncp = 5, graph = F).

nbperms

Numeric number of permutations used by the RDA.anova function. Default is 1000.

RDA.table.graph

TRUE or FALSE. TRUE = Display the RDA outputs table under PCA graphics.

RDA.table.graph.height

Numeric. Set the ratio of RDA table graphic height. Default is set to 1.

Size.RDA.table.graph

Numeric. Set the ratio of RDA table graphic size. Default is set to 7.

Get.generated.data.frame

TRUE or FALSE. TRUE = save the generated data frames for graphic constructions. Default = FALSE.

Value

Several graphics

Examples


library(FactoMineR)
my.PCA <- FactoMineR::PCA(mtcars[,1:7], scale.unit = FALSE, ncp = 5, graph = FALSE)
PCA_RDA_graphics(complete.data.set = mtcars, factor.names = c("vs", "gear"), PCA.object = my.PCA)



[Package GABB version 0.3.8 Index]