search for: viewport

Displaying 20 results from an estimated 651 matches for "viewport".

Did you mean: viewports
2003 Dec 30
0
grid's viewports
Hello! There is something wrong with nested viewports in grid package (I have tested it in R-1.8.0, may be it is different in other versions). Here is an simple example of a feature which seems strange to me: x11() rec<-T push.viewport(viewport(xscale=c(-10,10),yscale=c(-10,10),gp=gpar(col="magenta")),recording=rec) #Parent viewpor...
2007 Dec 26
1
seekViewport error
Why does the seekViewport at the bottom give an error? > xyplot(Sepal.Length ~ Sepal.Width, iris, group = Species, col = 11:13, + auto.key = TRUE) > grid.ls(view = TRUE) ROOT GRID.rect.89 plot1.toplevel.vp plot1.xlab.vp plot1.xlab 1 plot1.ylab.vp plot1.ylab 1 plot1.strip.1.1....
2008 Jun 01
1
transforming output of grid.locator() to coordinates of a leaf viewport
Short form: How do I transform the output of grid.locator() (or grid.locator(unit='npc')) to the native (or npc) coordinates of a viewport other than the top-level viewport? Thanks in advance. -Ben Long form: I would like the user to be able to click anywhere on the R graphics window. I would then like to figure out which leaf viewport the user clicked in and compute the native coordinates in that leaf viewport of the user'...
2008 Aug 06
1
grid layout scaling viewport width based solely on height
...pefully, my explanation makes my goal clear. Also note, the real application is a function that will have arbitrary numbers of side plots. Thanks Peter require(grid) grid.newpage() lout1 <- grid.layout(nrow = 1, ncol = 2, widths = unit(c(1, 1/10), c('null', 'snpc')) ) pushViewport(viewport(layout = lout1, w = 0.8, h = 0.8)) pushViewport(viewport(layout.pos.col = 1)) grid.rect() popViewport() pushViewport(viewport(layout.pos.col = 2)) lout2 <- grid.layout(nrow = 10, ncol = 1, heights = unit(1, 'snpc')) pushViewport(v...
2004 Apr 25
1
multipanel display of levelplots?
I cannot achieve a multipanel display of several levelplots. Here is part of my code. At first, create the layout: push.viewport(viewport(layout=grid.layout(1, 2))) Then for the left panel: push.viewport(viewport(layout.pos.col=1,layout.pos.row=1)) push.viewport(viewport(width=0.6, height=0.6)) levelplot(z~x*y, grid) pop.viewport() Similar code for the right panel. However, there is always error message for "pop.view...
2004 Sep 07
1
gridBase and heatmap
I would like to use gridBase to place four separate heatmaps (actually, a stripped-down heatmap.2 from ght gregmisc package that contains only the "image" part) into four different viewports. I can get the placement correct, but I keep 'losing' the previous plot. Any suggestions? Here is some quick example code trying to put a heatmap into the left viewport and then put a second one into the upper right. Thanks in advance for insight.... Sean > pushViewport(vie...
2008 Jan 15
1
navigating ggplot viewports
list(...) I can not get at the grid viewports in a ggplot2 plot. I know there is supposed to be a viewport called "panel_1_1" but downViewport() can't find it. Has the viewport been popped? I had a quick look at the functions involved (eg ggplot_plot) but there is no obvious problem there. > library(ggplot2) > qplot(1:10,...
2008 Aug 17
1
Making use of names of viewports (grid)
...----------------- require(grid) wide <- 15 vps <- grid.layout(nrow = 3, ncol = 4, widths = unit(rep(1, 4), rep("null", 4)), heights = unit(c(99, 1, 99), c("mm", "null", "mm"))) pushViewport(viewport(layout = vps)) for(k in 1:4){# label 4 viewports in top row cube.k <- ppaste("Cube", k) pushViewport(viewport(layout = vps, name = cube.k, layout.pos.row = 1, layout.pos.col = k)) grid.rect(gp = gpar(lty = &quot...
2009 Mar 31
1
viewport bug in 2.8.0?: Error: Cannot pop the top-level viewport (grid and graphics output mixed?)
I get the following error message followed by instability in R after the error message: Error: Cannot pop the top-level viewport (grid and graphics output mixed?) Have reduced something much more complex in my code to a simple test case. I run the following and then resize the window: X = seq (1,10) Y = X^2 opar <- par(no.readonly=TRUE, mar = c(2.5, 3.1, 1, 2)) grid.newpage() pushViewport (viewport(x=0,y=0,width=1...
2007 Oct 24
1
Rotated viewports in Grid
Hi all, I'm trying to generate a plot containing a scatterplot, with marginal densityplots for x and y. However, when I try to generate a vertical densityplot, I get the message "warning: can't clip to rotated viewport", and nothing shows up. I'm probably misunderstanding how viewports are meant to be used, so if someone could give me a hint, I'd be most grateful. my system is R 2.5.0 (stuck, and can't upgrade for now) and windoms xp. many thanks in advance, Gustaf example: -------------------...
2006 May 29
2
Feature Request: Viewport Switching Plugin
Hi, First of all, great job! :) I really like to organise my work on, former known "workspaces", now "viewports". I use currently use 9 so I have 3 for work, 3 for private applications and 3 for other projects. Using the viewports like this it happens to have 3 browser windows, 6 Document Viewers, 9 Terminals, 1 Evolution, 2 IDEs and >3 Gimp The number of Windows and the organisation on the diff...
2007 Feb 02
2
Horizontally maximized window on last viewport
...ou put into making it. I am using the latest git version of compiz and it really works great for being an "unstable" version. Anyway, I noticed the following strange behavior and was wondering if anybody else experince the same: When I have a window maximized horizontally on the last viewport (4) and try to switch to that window (using either switcher or scale) from the first viewport (1), the cube rotates to the proper viewport (4) but the window is moved to the first viewport (1). Shocked If I then swap to the first viewport (1) again to see the horizontally maximized window and then...
2005 May 31
2
Problem going back to a viewport with gridBase
I am setting up base plots -- one in viewport A and and one in B. This part works fine. But if I go back to A after having done B and add horizontal lines it seems to not use the correct coordinates. How do I tell it to resume using A's coordinates? I am already using par(fig = gridFIG()) but it seems that that's not enough to rees...
2005 May 31
2
Problem going back to a viewport with gridBase
I am setting up base plots -- one in viewport A and and one in B. This part works fine. But if I go back to A after having done B and add horizontal lines it seems to not use the correct coordinates. How do I tell it to resume using A's coordinates? I am already using par(fig = gridFIG()) but it seems that that's not enough to rees...
2009 Jul 21
2
animated grid graphics
I need to make a fairly complex animated graphic and decided to use grid for it. A very simple example of what I need: ##============================================================================== library(grid) grid.newpage() pushViewport(plotViewport()) pushViewport(viewport(xscale = extendrange(c(0, 100)), yscale = extendrange(c(0, 100)))) grid.xaxis() grid.yaxis() rectNames <- paste("r", 1:100, sep = "") for (i in 1:100) { grid.rect(x = unit(sample(0:100, 1), "native"),...
2003 Oct 19
0
Oceanographic lattice plots
...ion with a label area on top # (i.e., a Trellis-like arrangement) hence the "nrow*2". # The label area is 1 line high, the plot areas # consume the remaining height. # Maybe you could add extra rows and cols to this layout to # create small gaps between each plot # This layout is within a viewport which leaves margins for axes # and labels push.viewport(viewport(x=unit(4, "lines"), y=unit(4, "lines"), width=unit(1, "npc") - unit(6, "lines"), height=unit(1, "npc") - unit(6...
2006 May 21
1
print.trellis(..., draw.in=...)
A year ago I had posted this code https://stat.ethz.ch/pipermail/r-devel/2005-June/033508.html and the associated discussion was that there would be a print.trellis argument that could be used to eliminate the need for with.vpPath or with.viewport there. I assume that that is what draw.in= in print.trellis is for. When I try it I get an error. I did notice that ?print.trellis says draw.in= has not been well tested yet. Is this a bug? After running the the code at the end I get this error message: Error in downViewport.vpPath(vpPathDir...
2001 Sep 21
2
new versions of grid and lattice
...evelopment_ (they are in CRAN/src/contrib/Devel) There have been some bug fixes and, especially in lattice, there are lots of new features. Descriptions of the changes are included below. If you have any grid code, it may break under the new version because of a change to the interface of the pop.viewport() function -- see the changes below. Many thanks to those who have provided feedback and suggestions for corrections/improvements. Don't worry if you can't see your suggestion in the new version; it just means we haven't found time to try to implement it yet :) Paul Murrell Deepayan...
2001 Sep 21
2
new versions of grid and lattice
...evelopment_ (they are in CRAN/src/contrib/Devel) There have been some bug fixes and, especially in lattice, there are lots of new features. Descriptions of the changes are included below. If you have any grid code, it may break under the new version because of a change to the interface of the pop.viewport() function -- see the changes below. Many thanks to those who have provided feedback and suggestions for corrections/improvements. Don't worry if you can't see your suggestion in the new version; it just means we haven't found time to try to implement it yet :) Paul Murrell Deepayan...
2009 Jul 12
0
[PATCH 2/3] nv50: fix viewport transform
We need to invert the viewport translate/scale parameters when the state tracker thinks we have Y_0_TOP. If these cases, we have do to bypass mode by setting an identity viewport transform for x, z and inversion for y, or p.e. clear_with_quad won't work correctly. Clipping for xy in NDC space needs to be disabled then. ---...