polynomial2 function

Analysis: Linear regression graph in double factorial

Analysis: Linear regression graph in double factorial

Linear regression analysis for significant interaction of an experiment with two factors, one quantitative and one qualitative

polynomial2( fator1, resp, fator2, color = NA, grau = NA, ylab = "Response", xlab = "Independent", theme = theme_classic(), se = FALSE, point = "mean_sd", legend.title = "Treatments", posi = "top", textsize = 12, ylim = NA, family = "sans", width.bar = NA, pointsize = 3, linesize = 0.8, separate = c("(\"", "\")"), n = NA, DFres = NA, SSq = NA )

Arguments

  • fator1: Numeric or complex vector with factor 1 levels
  • resp: Numerical vector containing the response of the experiment.
  • fator2: Numeric or complex vector with factor 2 levels
  • color: Graph color (default is NA)
  • grau: Degree of the polynomial (1,2 or 3)
  • ylab: Dependent variable name (Accepts the expression() function)
  • xlab: Independent variable name (Accepts the expression() function)
  • theme: ggplot2 theme (default is theme_classic())
  • se: Adds confidence interval (default is FALSE)
  • point: Defines whether to plot all points ("all"), mean ("mean"), mean with standard deviation (default - "mean_sd") or mean with standard error ("mean_se").
  • legend.title: Title legend
  • posi: Legend position
  • textsize: Font size (default is 12)
  • ylim: y-axis scale
  • family: Font family (default is sans)
  • width.bar: width of the error bars of a regression graph.
  • pointsize: Point size (default is 4)
  • linesize: line size (Trendline and Error Bar)
  • separate: Separation between treatment and equation (default is c("("","")"))
  • n: Number of decimal places for regression equations
  • DFres: Residue freedom degrees
  • SSq: Sum of squares of the residue

Returns

Returns two or more linear, quadratic or cubic regression analyzes.

Examples

dose=rep(c(0,0,0,2,2,2,4,4,4,6,6,6),3) resp=c(8,7,5,23,24,25,30,34,36,80,90,80, 12,14,15,23,24,25,50,54,56,80,90,40, 12,14,15,3,4,5,50,54,56,80,90,40) trat=rep(c("A","B","C"),e=12) polynomial2(dose, resp, trat, grau=c(1,2,3))

See Also

polynomial , polynomial2_color

Author(s)

Gabriel Danilo Shimizu, shimizu@uel.br

Leandro Simoes Azeredo Goncalves

Rodrigo Yudi Palhaci Marubayashi