Hello, I have a somewhat complicated question and hope, someone can help me or that there is a solution at all for my problem. I am using R to plot the results of a Voronoi-Tesselation. I am however only interested in a small part of the plot, around the center. Is there a way to cut out the central part of the plot and enlarge it in R? I have quite a few of these plots and cutting and enlarging the image manually with another software is only the last option, if there is no other way to do it. I hope this explains my problem clearly enough and there is a solution for it. Many thanks in advance! Raphael
It will be easier for folks to help you if you provide example code that produces a plot like the one you are dealing with. Jean On Tue, Jan 6, 2015 at 11:23 AM, Raphael P?bst <raphael.paebst at gmail.com> wrote:> Hello, > I have a somewhat complicated question and hope, someone can help me > or that there is a solution at all for my problem. > I am using R to plot the results of a Voronoi-Tesselation. I am > however only interested in a small part of the plot, around the > center. Is there a way to cut out the central part of the plot and > enlarge it in R? I have quite a few of these plots and cutting and > enlarging the image manually with another software is only the last > option, if there is no other way to do it. > > I hope this explains my problem clearly enough and there is a solution for > it. > > Many thanks in advance! > > Raphael > > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > 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]]
The relevant bit of code should be this one: #Getting a list of Voronoi-Cells: VoronoiCells <- tile.list(DelTriCor) # plotting all of them: figure() plot(VoronoiCells,fillcol=CellColor,close=TRUE,xlim=xlim,ylim=ylim) I hope this helps. All the best! Raphael On 1/6/15, Adams, Jean <jvadams at usgs.gov> wrote:> It will be easier for folks to help you if you provide example code that > produces a plot like the one you are dealing with. > > Jean > > On Tue, Jan 6, 2015 at 11:23 AM, Raphael P?bst <raphael.paebst at gmail.com> > wrote: > >> Hello, >> I have a somewhat complicated question and hope, someone can help me >> or that there is a solution at all for my problem. >> I am using R to plot the results of a Voronoi-Tesselation. I am >> however only interested in a small part of the plot, around the >> center. Is there a way to cut out the central part of the plot and >> enlarge it in R? I have quite a few of these plots and cutting and >> enlarging the image manually with another software is only the last >> option, if there is no other way to do it. >> >> I hope this explains my problem clearly enough and there is a solution >> for >> it. >> >> Many thanks in advance! >> >> Raphael >> >> ______________________________________________ >> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see >> 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. >> >
Is this what you are looking for. This is in lattice graphics. library(lattice) x <- seq(0, 4*pi, length=101) y <- sin(x) G <- xyplot(y ~ x, type="l") G H <- update(G, xlim=c(4,6), ylim=c(-1, -.4)) H On Tue, Jan 6, 2015 at 12:23 PM, Raphael P?bst <raphael.paebst at gmail.com> wrote:> Hello, > I have a somewhat complicated question and hope, someone can help me > or that there is a solution at all for my problem. > I am using R to plot the results of a Voronoi-Tesselation. I am > however only interested in a small part of the plot, around the > center. Is there a way to cut out the central part of the plot and > enlarge it in R? I have quite a few of these plots and cutting and > enlarging the image manually with another software is only the last > option, if there is no other way to do it. > > I hope this explains my problem clearly enough and there is a solution for it. > > Many thanks in advance! > > Raphael > > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > 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.
I don't think this has any relevance. The deldir package doesn't use lattice graphics. I think that Jean Adams has answered the OP's question adequately. cheers, Rolf On 07/01/15 07:05, Richard M. Heiberger wrote:> Is this what you are looking for. This is in lattice graphics. > > library(lattice) > x <- seq(0, 4*pi, length=101) > y <- sin(x) > G <- xyplot(y ~ x, type="l") > G > H <- update(G, xlim=c(4,6), ylim=c(-1, -.4)) > H > > On Tue, Jan 6, 2015 at 12:23 PM, Raphael P?bst <raphael.paebst at gmail.com> wrote: >> Hello, >> I have a somewhat complicated question and hope, someone can help me >> or that there is a solution at all for my problem. >> I am using R to plot the results of a Voronoi-Tesselation. I am >> however only interested in a small part of the plot, around the >> center. Is there a way to cut out the central part of the plot and >> enlarge it in R? I have quite a few of these plots and cutting and >> enlarging the image manually with another software is only the last >> option, if there is no other way to do it. >> >> I hope this explains my problem clearly enough and there is a solution for it.-- Rolf Turner Technical Editor ANZJS