Description Usage Arguments Value Examples
View source: R/simpleScatter.R
A minimal function to produce a ggplot object from two continuous varaibles.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
data |
frame to be used. |
x |
X (independent) variable to be plotted. |
y |
Y (dependent) variable to be plotted. |
xlab |
Label (optional) to be placed on the x axis. |
ylab |
Label (optional) to be placed on the y axis. |
title |
Title (optional) of the chart. |
subtitle |
Subtitle (optional) of the chart. |
xlim |
Typical xlim option to limit the graphed regions of the chart. |
ylim |
Typical ylim option to limit the graphed regions of the chart. |
line |
Logical: add linear fit line to plot? |
interval |
Option denoting the type of interval to be plotted around linear prediction line. Option "none" is default. Other options include "confidence" and "prediction". Use of any option other than "none" will automatically change line=TRUE. |
ptalpha |
Alpha value (opacity) of the points graphed. Defaults to 0.8. |
... |
Further arguments passed to or from other methods. |
ggplot object
1 2 | m <- mtcars
simpleScatter(m, disp, hp, title="Horsepower from Displacement")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.