gap.plot {plotrix} | R Documentation |
Displays a plot with a missing range.
gap.plot(x,y,gap,gap.side="y",xaxlab,xtics,yaxlab,ytics, col=par("col"),...)
x,y |
data values |
gap |
the range of values to be left out |
gap.side |
whether the gap is to be on the x or y axis |
xaxlab |
labels for the x axis ticks |
xtics |
position of the x axis ticks |
yaxlab |
labels for the y axis ticks |
ytics |
position of the y axis ticks |
col |
color(s) in which to plot the values |
... |
arguments passed to plot . |
Displays a plot omitting a range of values on one axis. Typically used
when there is a relatively large gap in the overall range of one set of
values. See axis.break
for a brief discussion of plotting
on discontinuous coordinates.
nil
Jim Lemon and Ben Bolker
twogrp<-c(rnorm(10)+4,rnorm(10)+20) gap.plot(twogrp,gap=c(8,16),xlab="Index",ylab="Group values", main="Plot gap on Y axis") if(dev.interactive()) par(ask=TRUE) gap.plot(twogrp,rnorm(20),gap=c(8,16),gap.side="x",xlab="X values", xtics=c(4,7,17,20),ylab="Y values",main="Plot gap on X axis") par(ask=FALSE)