scatter: Correlation scatter plot.

Description Usage Arguments Value Examples

View source: R/scatter.R

Description

scatter function will draw scatter plot for correlation analysis.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
scatter(
  data,
  x,
  y,
  col.var = NULL,
  size.var = NULL,
  method = "loess",
  title = NULL,
  subtitle = NULL,
  xtitle = NULL,
  ytitle = NULL,
  caption = NULL
)

Arguments

data

input data.frame

x

x variable

y

y variable

col.var

color variable

size.var

size variable

method

regression method type,default is "loess"

title

main title

subtitle

subtitle

xtitle

x axis title

ytitle

y axis title

caption

caption

Value

An object of class ggplot

Examples

1
2
3
4
5
6
#area chart
plot<- scatter(data=iris, x="Sepal.Length", y="Sepal.Width", col.var = "Species", size.var = "Petal.Length",
               method="lm",
               title="Scatter", subtitle="plot", xtitle="Sepal.Length", ytitle="Sepal.Width", caption="iris")

plot

HeeseokMoon/ggedachart documentation built on Dec. 31, 2020, 12:59 p.m.