Hi All, I wonder whether it is possible to use the plot function and reduce the scales on both +/- quadrants, i.e. plot the data from -15. -8 and 8..15 only. Many thanks
On 29-09-2012, at 15:33, Sabine Dietmann <sabine.dietmann at gmail.com> wrote:> Hi All, > > I wonder whether it is possible to use the plot function and reduce > the scales on both +/- quadrants, i.e. > plot the data from -15. -8 and 8..15 only. >Have a look at ?plot.default and try plot(x,y,xlim=c(-15,-8),ylim=c(8,15)) assuming that you are trying an (x,y) plot. Berend
On Sep 29, 2012, at 6:33 AM, Sabine Dietmann wrote:> Hi All, > > I wonder whether it is possible to use the plot function and reduce > the scales on both +/- quadrants, i.e.Those are not quadrants, but rather half-planes.> plot the data from -15. -8 and 8..15 only.There is a broken axis function. gap.plot, in package plotrix. -- David Winsemius, MD Alameda, CA, USA
On 09/29/2012 11:33 PM, Sabine Dietmann wrote:> Hi All, > > I wonder whether it is possible to use the plot function and reduce > the scales on both +/- quadrants, i.e. > plot the data from -15. -8 and 8..15 only. >Hi Sabine, As David noted, you might want gap.plot: library(plotrix) testdat<-c(sample(-15:-8,6),sample(8:15,6)) gap.plot(testdat,gap=c(-7,7), main="Gap on Y axis") gap.plot(testdat,rnorm(12),gap=c(-7,7), main="Gap on X axis",gap.axis="x") Jim