Learn R Programming

HelpersMG (version 5.1)

plot_add: Add a plot to a previous one

Description

To plot data, just add use it as a normal plot. It will plot the new data without axes, or labels for axes. This function is complementary to matlines() and matpoints() from package graphics.

Usage

plot_add(...)

Arguments

...

Parameters for plot()

Value

Nothing

Details

plot_add adds a plot to a previous one

See Also

Other plot and barplot functions: ScalePreviousPlot(), barplot_errbar(), plot_errbar(), show_name()

Examples

Run this code
# NOT RUN {
plot(x=1:100, y=sin(1:100), type="l", bty="n", xlim=c(1,200), xlab="x", ylab="y")
plot_add(x=1:200, y=cos(1:200), type="l", bty="n", col="red")
# }

Run the code above in your browser using DataLab