correlation {AgroReg}R Documentation

Graph: Plot correlation

Description

Correlation analysis function (Pearson or Spearman)

Usage

correlation(
  x,
  y,
  method = "pearson",
  ylab = "Dependent",
  xlab = "Independent",
  theme = theme_classic(),
  textsize = 12,
  pointsize = 5,
  pointshape = 21,
  linesize = 0.8,
  fill.ic = "gray70",
  alpha.ic = 0.5,
  ic = TRUE,
  title = NA,
  fontfamily = "sans"
)

Arguments

x

Numeric vector with independent variable

y

Numeric vector with dependent variable

method

Method correlation (default is Pearson)

ylab

Variable response name (Accepts the expression() function)

xlab

Treatments name (Accepts the expression() function)

theme

ggplot2 theme (default is theme_classic())

textsize

Axis text size

pointsize

Point size

pointshape

shape format

linesize

line size

fill.ic

Color interval of confidence

alpha.ic

confidence interval transparency level

ic

Add interval of confidence

title

title

fontfamily

Font family

Value

The function returns a graph for correlation

Author(s)

Gabriel Danilo Shimizu, shimizu@uel.br

Leandro Simoes Azeredo Goncalves

Examples

data("aristolochia")
with(aristolochia, correlation(trat,resp))

[Package AgroReg version 1.2.10 Index]