Displaying 14 results from an estimated 14 matches for "vppath".
Did you mean:
vpath
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...
2008 May 02
1
Error in downViewport.vpPath(vpPathDirect(name)
Hi,
I am having trouble plotting a series of dendrograms using lattice and grid
code as found in Paul Murrells book R Graphics.
This is the error message I recieve:
Error in downViewport.vpPath(vpPathDirect(name), strict, recording =
recording) :
Viewport 'plot1.panel.1.1.off.vp' was not found
I have attached the code and also my data file. Should anyone have any
suggestions then your help would be gratefully appreciated.
Thank you
Andrew
http://www.nabble.com/file/p17017801...
2005 Oct 03
1
Grid: constructing a gTree with grobs that use named viewports from a vpTree
...he following code:
grid.newpage()
pushViewport(vp)
upViewport(1)
grid.draw(grobs)
But I want a grob that represents those grobs drawn in the appropriate
viewports. I had hoped I could do something like:
grid.newpage()
grid.draw(gTree(vp=vp, children = grobs))
But I get:
Error in downViewport.vpPath(vp, strict = TRUE, recording = FALSE) :
Viewport 'tl' was not found
presumably because no equivalent of the upViewport(1) command is used.
What should I be doing here?
Thanks,
Hadley
2007 Jan 01
3
Wish list
...038497.html
2. Grid
- logical-valued function as first arg of grid.edit
- transparency under Windows (not sure if this involves grid
or just the Windows graphics device)
- shading patterns
- more interactivity features
- safe way to get name of a grid object, e.g.
names.vpPath <- names.viewport <- function(x) x$name
- safe way to get children of a grid object
getChildren.viewport <- function(x) x$children
and the order; see:
https://www.stat.math.ethz.ch/pipermail/r-devel/2005-June/033532.html
- facility for using a name, viewport or vpPa...
2008 Jan 15
1
navigating ggplot viewports
...) 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, 1:10)
> current.viewport()
viewport[ROOT]
> downViewport("panel_1_1")
Error in downViewport.vpPath(vpPathDirect(name), strict, recording =
recording) :
Viewport 'panel_1_1' was not found
> current.vpTree()
viewport[ROOT]->(viewport[GRID.VP.1])
> grid.ls(viewports=T, grob=F)
ROOT
GRID.VP.2
1
GRID.VP.3
layout
strip_h_1_1
1
strip_v_1_1
1...
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 reestablish them. What happens is that when I go back to
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 reestablish them. What happens is that when I go back to
2005 Oct 11
1
aligning column of xyplots and removing space between them
...ge()
pushLayout <- function(nr, nc, ..., name="layout") {
pushViewport(viewport(layout=grid.layout(nr, nc, ...), name=name))
for (i in 1:nr) {
for (j in 1:nc) {
pushViewport(viewport(layout.pos.row=i, layout.pos.col=j))
upViewport()
}
}
upViewport()
}
with.vpPath <-
with.viewport <- function(data, expr, ...) {
# if data is a vpPath it cannot be ROOT since NULL will not dispatch here
depth <- if (data$name == "ROOT") 0 else downViewport(data$name)
result <- eval.parent(substitute(expr))
upViewport(depth)
in...
2006 Jul 19
1
plain shading (not residuals) in mosaic plot
...ngly, it didn't work:
> mosaicplot(morphs3,color=c(grey(0.8),grey(0.4)),pop=FALSE)
Warning message:
extra argument(s) 'pop' will be disregarded in:
mosaicplot.default(morphs3, color = c(grey(0.8), grey(0.4)),
> labeling_cells(text=morphs3,margin=0)(morphs3)
Error in downViewport.vpPath(vpPathDirect(name), strict, recording =
recording) : Viewport 'cell:Stem-initial obstruent=p,Behavior
according to dictionary=unsubstituted' was not found
Does anyone know how to get both the shading I want and the labels I
want, whether with mosaic(), with mosaicplot(), or in s...
2006 Jul 29
3
placing rectangle behind plot
I am trying to create a lattice plot and would like to later, i.e. after
the plot is drawn, add a grey rectangle behind a portion of it.
The following works except that the rectrangle is on top of and
obscures a portion of the chart. I also tried adding col = "transparent"
to the gpar list but that did not help -- I am on windows and
perhaps the windows device does not support
2007 Dec 26
1
seekViewport error
...GRID.points.79
1
GRID.VP.23
GRID.cellGrob.82
GRID.points.81
1
GRID.VP.24
GRID.cellGrob.84
GRID.points.83
1
1
plot1.
1
1
> seekViewport("GRID.VP.24")
Error in downViewport.vpPath(vpPathDirect(name), strict, recording =
recording) :
Viewport 'GRID.VP.24' was not found
> R.version.string # Vista
[1] "R version 2.6.1 Patched (2007-12-06 r43610)"
> packageDescription("grid")$Version
[1] "2.6.1"
> packageDescription("lattice...
2005 Nov 02
0
Placing a grob in multiple viewports
...n using code like:
plot_grob_matrix <- function(gm, type=deparse(substitute(gm))) {
grid <- expand.grid(x=1:nrow(gm), y=1:ncol(gm))
do.call(gList,mapply(function(x,y) editGrob(gm[[x,y]], vp=vp_path(x,
y, type)), grid$x, grid$y, SIMPLIFY=FALSE))
}
vp_path <- function(row, col, type) {
vpPath("layout", paste(type, row, col, sep="_"))
}
to place a matrix of grobs into a similar looking matrix of viewports
(constructed by another function). This works fine if the matrix
contains different grobs, but only draws one if they are all the same
(obviously due to the copy...
2004 Apr 12
1
R 1.9.0 is release
...ons within single grid.polygon() call.
- Added vpList(), vpStack(), vpTree(), and current.vpTree()
to allow creation of viewport "bundles" that may be pushed
at once (lists are pushed in parallel, stacks in series).
current.vpTree() returns the current viewport tree.
- Added vpPath() to allow specification of viewport path
in downViewport() and seekViewport().
See ?viewports for an example of its use.
NOTE: it is also possible to specify a path directly,
e.g., something like "vp1::vp2", but this is only
advised for interactive use (in case I decide...
2004 Apr 12
1
R 1.9.0 is release
...ons within single grid.polygon() call.
- Added vpList(), vpStack(), vpTree(), and current.vpTree()
to allow creation of viewport "bundles" that may be pushed
at once (lists are pushed in parallel, stacks in series).
current.vpTree() returns the current viewport tree.
- Added vpPath() to allow specification of viewport path
in downViewport() and seekViewport().
See ?viewports for an example of its use.
NOTE: it is also possible to specify a path directly,
e.g., something like "vp1::vp2", but this is only
advised for interactive use (in case I decide...