[R] Plot Axes

Gavin Simpson gavin.simpson at ucl.ac.uk
Thu Nov 11 13:52:22 CET 2010

On Thu, 2010-11-11 at 01:41 -0800, dpender wrote:
> Thanks  Jim,
> The next issue is how i get the RP lines to cut the axes. The lines either
> cut the x axis at D=35 or the y axis at H=4.5.
> How do I set the axes so that the lines start and end on the axes?
> http://r.789695.n4.nabble.com/file/n3037496/plot.jpeg 

See ?par and in particular 'xaxs' and 'yaxs'


plot(1:10, xaxs = "i", yaxs = "i")

 Dr. Gavin Simpson             [t] +44 (0)20 7679 0522
 ECRC, UCL Geography,          [f] +44 (0)20 7679 0565
 Pearson Building,             [e] gavin.simpsonATNOSPAMucl.ac.uk
 Gower Street, London          [w] http://www.ucl.ac.uk/~ucfagls/
 UK. WC1E 6BT.                 [w] http://www.freshwaters.org.uk

More information about the R-help mailing list