in a simple plot. When i do plot is it possible to zoom in or out or this is not possible at all? Best Regards Alex [[alternative HTML version deleted]]
Hi Alex, After you have created the plot I do not know of a way to zoom (in base graphics), but you can always use the xlim and ylim arguments to focus on a particular area (or effectively zoom) when you are create the plot. For instance, plot(x = 1:10, y = 1:10) plot(x = 1:10, y = 1:10, xlim = c(3, 5), y = c(4, 10)) Cheers, Josh On Tue, Oct 26, 2010 at 8:30 AM, Alaios <alaios at yahoo.com> wrote:> in a simple plot. When i do plot is it possible to zoom in or out or this is not > possible at all? > > Best Regards > Alex > > > > > ? ? ? ?[[alternative HTML version deleted]] > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. >-- Joshua Wiley Ph.D. Student, Health Psychology University of California, Los Angeles http://www.joshuawiley.com/
I think that this would be possible if you save the graph to a scalable format. Try looking into: ?postscript ?xfig ?pdf -------------------------------------- Jonathan P. Daily Technician - USGS Leetown Science Center 11649 Leetown Road Kearneysville WV, 25430 (304) 724-4480 "Is the room still a room when its empty? Does the room, the thing itself have purpose? Or do we, what's the word... imbue it." - Jubal Early, Firefly From: Alaios <alaios@yahoo.com> To: Rhelp <r-help@r-project.org> Date: 10/26/2010 11:32 AM Subject: [R] Zoom in in a plot Sent by: r-help-bounces@r-project.org in a simple plot. When i do plot is it possible to zoom in or out or this is not possible at all? Best Regards Alex [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. [[alternative HTML version deleted]]
On Oct 26, 2010, at 8:30 AM, Alaios wrote:> in a simple plot. When i do plot is it possible to zoom in or out or > this is not > possible at all? >Zoom? Do you mean restrict the region plotted to specific ranges? xlim and ylim arguments provide that facility. -- David.> Best Regards > Alex
On 26/10/2010 11:30 AM, Alaios wrote:> in a simple plot. When i do plot is it possible to zoom in or out or this is not > possible at all?There's no general support for that, but you could conceivably write it yourself using getGraphicsEvent. The example code there adjusts xlim and ylim according to mouse movements. It works reasonably well in Windows or the device in the cairoDevice package, and is sometimes acceptable in X11. Other devices don't have the necessary support for it. Duncan Murdoch
For a quick exploration of the plot you can use the zoomplot function in the TeachingDemos package. But for production graphs it is better to explicitly set the xlim and ylim parameters in creating the plot up front. -- Gregory (Greg) L. Snow Ph.D. Statistical Data Center Intermountain Healthcare greg.snow at imail.org 801.408.8111> -----Original Message----- > From: r-help-bounces at r-project.org [mailto:r-help-bounces at r- > project.org] On Behalf Of Alaios > Sent: Tuesday, October 26, 2010 9:31 AM > To: Rhelp > Subject: [R] Zoom in in a plot > > in a simple plot. When i do plot is it possible to zoom in or out or > this is not > possible at all? > > Best Regards > Alex > > > > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting- > guide.html > and provide commented, minimal, self-contained, reproducible code.