Displaying 20 results from an estimated 1000 matches similar to: "childNames for xaxis grob (grid package)"
2005 Oct 03
2
grob questions
If I run the following example from:
http://www.stat.auckland.ac.nz/~paul/grid/doc/grobs.pdf
> grid.newpage()
> pushViewport(viewport(w = 0.5, h = 0.5))
> myplot <- gTree(name = "myplot", children = gList(rectGrob(name = "box",
+ gp = gpar(col = "grey")), xaxisGrob(name = "xaxis")))
> grid.draw(myplot)
>
2008 Jan 14
2
Need help with xspline error message in R 2.6.1 on Windows XP
I am attempting to generate a series of plots with cubic B-Splines and
the code I am using is generating the following error message that I
have been unable to resolve.
Error in grid.Call.graphics("L_xspline", x$x, x$y, x$shape, x$open,
x$arrow, : add_point - reached MAXNUMPTS (25200)
This is the code that generates this error.
plot.results <- function(dfn) {
dt <-
2011 Aug 18
1
Where are the ticks on grid.xaxis?
Hi R list,
I like the default ticks that are set up using grid.xaxis() or grid.yaxis()
with no arguments. Finding good values for the 'at' argument is usually not
a trivial task; the default behavior of these functions seems to work well.
The problem with this strategy is that I cannot figure out how to "recover"
the positions of these ticks when you do NOT specify the
2009 Sep 27
0
puzzle with drawDetails for a class derived from a gTree
Dear all,
I've tried all sorts of variations discussed in "R graphics" by Paul
Murrell, but I still can't understand how to write a drawDetails
method for a class derived from a gTree.
Below is a minimal, dummy example where two strings are plotted in two
separate viewports. I require the creation of the strings to be
evaluated inside the drawDetails function because my real
2005 Oct 03
1
Grid: constructing a gTree with grobs that use named viewports from a vpTree
I'm trying to create a layout with named viewports that I can use for
other functions. I create the viewport tree that I want, and a list
of grobs with the viewports describing where they should go.
library(grid)
vp <- vpTree(
viewport(layout=grid.layout(2,2), name="layout"),
children=vpList(
viewport(layout.pos.col = 1, layout.pos.row=1, name="tl"),
2010 Mar 19
2
lattice grob
Dear list,
I'm trying to arrange various grid objects on a page using a
frameGrob. It works fine with basic grobs (textGrob, gTree, etc.), and
also with ggplot2 objects using the ggplotGrob() function. I am
however stuck with lattice. As far as I understand, lattice produces a
list of class trellis, which is eventually displayed using the
plot.trellis method. I am not sure if/how one can
2007 Aug 08
1
Help using gPath
Hi everyone,I'm trying to figure out how to use gPath and the documentation
is not very helpful :(
I have the following plot object:
plot-surrounds::
background
plot.gTree.378::
background
guide.gTree.355:: (background.rect.345, minor-horizontal.segments.347,
minor-vertical.segments.349, major-horizontal.segments.351,
major-vertical.segments.353)
guide.gTree.356::
2009 Sep 19
1
matrix operations on grobs and grid units
Dear list,
As a minimal test of a more complex grid layout, I'm trying to find a
clean and efficient way to arrange text grobs in a rectangular layout.
The labels may be expressions, or text with a fontsize different of
the default, which means that the cell sizes should probably be
calculated using grobWidth() and grobHeight() as opposed to simpler
stringWidth() and stringHeight().
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()
2012 May 22
2
package grid: mirror grob objects along an axis
Hi everyone
I'd like to flip grobs (grid graphical objects) along an axis, e.g. flip grobs
horizontally or vertically. I couldn't find any hints, neither in the
documentation nor by searching the web. Does anybody know how to achieve this?
Cheers
/thomas
2009 May 31
2
grid.edit() for ggplot2
Dear all,
I'm trying to access and modify grobs in a ggplot2 plot. The basic
idea for raw Grid objects I understand from Paul Murrell's R graphics
book, or this page of examples,
http://www.stat.auckland.ac.nz/~paul/grid/copygrob/copygrobs.R
However I can't figure out how to apply this to a ggplot (basically I
don't know how to write a syntactically correct gPath),
p
2007 Dec 18
1
ggplot2 - getting at the grobs
Dear All,
I continue trying to get several of my plotting functions to use
ggplot, because I really do like the concept of the graphical
objects, and working with them in the abstract.
I am now trying to access the grobs to manipulate using grid.
However, until now all I managed was to get the plot as a gTree
object, and manipulate it as a gTree from there. The problem is that
then it is no
2008 Sep 29
2
ggplot 2 - editing in the "panel_1_1" viewport
Hi All,
I am trying to find out how to access the components of a ggplot plot, and I
found this reply from Paul Murrel
http://www.nabble.com/navigating-ggplot-viewports-tt14826352.html#a15056223.
I tried it, and it works.
However, I am trying to develop some functions that will do the drawing
"automatically", and usually I will not know the full name of the grob that
has the layout vp,
2002 Nov 27
2
grid package and lines
Hello list,
When using the grid package in R 1.60 under windows grid.lines and
grid.line.to seem not to use the coordinate system as defined by the current
viewport whereas grin.points does. Am I doing something wrong?
Sten
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send
2009 Jun 23
2
curvedarrow (some graphics problem)
Hi there,
I just wonder how to draw this kind of picture...
http://www.nabble.com/file/p24158796/b.jpg
http://www.nabble.com/file/p24158796/a.jpg
and this is what i have done
%%%%%
library(shape)
library(diagram)
curve(sin(x),bty="n",-8,8,yaxt="n",ylab="",xaxt="n",type="n",xlab="")
axis(1,labels=F,at=seq(-8,8,1))
2007 Jun 29
1
Print grid/ggplot to a metafile
Dear UseRs called Hadley, or Paul,
I am trying to print an edited ggplot2/grid graphics to a metafile. With the
commented line below it works, but when I edit the plot by uncommenting the
line, it fails, because it's illegal to have 2 graphics in a metafile. It
works with pdf, but even then I get two plots, which is a nuisance.
I found a workaround by using windows(); savePlot, but it only
2009 Oct 27
0
boxplot using grid
----------------------- *** Disclaimer *** -----------------------
This e-mail and its contents are subject to the SA Reserve Bank's
Disclaimer and Confidentiality Clause, which can be viewed at:
http://www.reservebank.co.za/disclaimer
Should you be unable to access the link provided, please send a
blank e-mail to Disclaimer@resbank.co.za
----------------------- *** Disclaimer ***
2003 May 12
3
grid - deleting and erasing grobs?
Hello!
Don't quite understand how can I delete grobs and simultaneously erase
graphic output they produce. I first change grob's "vp" field to null
(grid.edit(gr,vp=NULL)) to erase it and then call rm(gr) (as grobs are
external pointers I'm not shure what this method actually frees
allocated memory).
May be there is simpler method?
Does garbage collector have any effect
2003 May 12
3
grid - deleting and erasing grobs?
Hello!
Don't quite understand how can I delete grobs and simultaneously erase
graphic output they produce. I first change grob's "vp" field to null
(grid.edit(gr,vp=NULL)) to erase it and then call rm(gr) (as grobs are
external pointers I'm not shure what this method actually frees
allocated memory).
May be there is simpler method?
Does garbage collector have any effect
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