Displaying 20 results from an estimated 20000 matches similar to: "printing lattice plots"
2004 Jun 24
2
More problems with lattice and postscript
Dear List members,
I am trying to produce some trellis graphics and to save them in a
postscript file but I only get blank files. R behaviour is certainly
strange because I use a loop to generate the graphics (see code below).
When I change the loop variable myself the postscript graphics are OK.
I am using R 1.9.1 (2004-06-21) on Debian GNU/Linux which I try to keep
updated on a daily basis. I
2004 Nov 20
1
how to suppress whiskers in a bwplot?
dear R-help,
i have looked carefully through the R-help archives for information on how
to suppress whiskers in a bwplot. someone asked this question a while
ago, but the answer he received is not available in the archives.
but i did manage to get my hands on a panel function (called
"my.panel") that is supposed to do this (the function is reproduced at the
end of the email, below).
2005 Jul 28
2
lattice/ grid.layout/ multiple graphs per page
Background:
OS: Linux Mandrake 10.1
release: R 2.0.0
editor: GNU Emacs 21.3.2
front-end: ESS 5.2.3
---------------------------------
Colleagues
I have a set of lattice plots, and want to plot 4 of them on the page.
I am having trouble with the layout.
grid.newpage()
pushViewport(viewport(layout = grid.layout(2,2)))
pushviewport(viewport(layout.pos.col = 1, layout.pos.row = 1))
working trellis
2012 Apr 07
6
Drawing a line in xyplot
i am trying to replicate the following graph using xyplot :
attach(x)
plot ( jitter(type), mortality, pch=16, xlim = c(0.25, 3.75))
lines ( c(1-0.375,1.375) , c ( median(mortality[type==1]),
median(mortality[type==1])), lwd=5,col=2)
lines ( c(2-0.375,2.375) , c ( median(mortality[type==2]),
median(mortality[type==2])), lwd=5,col=2)
lines ( c(3-0.375,3.375) , c ( median(mortality[type==3]),
2003 Sep 09
1
lattice plot - portrait / landscape
Hi,
How can I use portrait/landscape option in lattice
bwplot? Is there any option in trellis.device where I
can define this?
Thanks in advance,
Mahbub.
2001 Oct 29
2
times 'til first change
There is probably an elegant and efficient way to do this -- perhaps
already implemented, and some of you knows it. Myself, I'm getting stuck
in long loops ...
Here is the question:
I have a long (80,000 + obs) binary time series.
For each of its elements I'd like to compute and save in a vector "the
number of steps 'til the first switch of state happens". For example,
2013 May 03
1
print multiple plots to jpeg, one lattice and one ggplot2
hello everybody,
I want to print two plots in one png file, I tried several options but i
didn't succeed
the first plot (bwplot) print to the defined position, but the second
(ggplot) doesn't
Any idea?
Thanks a lot
Christophe
# Example:
#-------------------------------------
library(ggplot2)
library(lattice)
library(grid)
one <- bwplot(decrease ~ treatment, OrchardSprays, groups
2006 Apr 13
1
panel.abline() and trellis.focus() on multipage plots
Hi,
I'm recently working on a multipage bwplot() using the lattice package. In
this context I was trying to use the panel.abline() function individually on
certain panels but not all. After some research I found the trellis.focus()
and trellis.unfocus() functions which enabled me to do something like:
trellis.focus("panel", 1, 3)
do.call("panel.abline", list
2002 Apr 18
2
Background in lattice plots using dotplot()
platform i586-pc-linux-gnu
arch i586
os linux-gnu
system i586, linux-gnu
status
major 1
minor 4.1
year 2002
month 01
day 30
language R
I can't seem to get rid of the slightly green background when I use
dotplot(). It shows on the screen in the
2003 Aug 05
2
bwplot colours
Dear All,
is any way I can change the colours of the box and umbrella of a bwplot
without having to go to the length of:
box.rectangle<-trellis.par.get("box.rectangle")
box.rectangle$col<-"black"
trellis.par.set("box.rectangle", box.rectangle)
etc...
but straight from the call:
bwplot(y ~ x | z, mydata) ?
Regards,
Federico Calboli
2002 Sep 23
4
How do I change plot colors in bwplot
Hello,
I'm using bwplot to make a few plots. The plots are exactly what I
need, but are coming out with a grey background and turquoise boxes and
whiskers. I cannot figure out how to just get black and white to be
the default. Can anyone help me with this?
Thanks
Kenneth E. Nussear Phone 775 784-1703
Ecology, Evolution and FAX 775 784-1369
2011 Jul 29
2
Multifactor boxplots
Dear All
I would like to produce interaction boxplots and this seems to work:
par(mfrow=c(2,2))
A=sample(rnorm(50,50,10))
B=sample(rnorm(50,100,10))
Test=merge(A,B,by=0)#by=0 where 0 is the row.names
TreatA=(gl(2,50,100,labels=c("High","Low")))
TreatB=rep(gl(2,25,50,labels=c("High","Low")),2)
Newdata=data.frame(TreatA,TreatB,Test)
2008 May 06
2
Lattice problems / cannot load lattice
Hi,
My problem is simple: since having updated the lattice package, I cannot
load lattice anymore. If I type in the command 'library(lattice)' the
loading fails with the following message:
--- cut here ---
Error in library.dynam(lib, package, package.lib) :
shared library 'lattice' not found
In addition: Warning messages:
1: In loadNamespace(package, c(which.lib.loc,
2005 Feb 01
2
How to write a new "top-level" Trellis/lattice function?
Hello,
I am trying to write a new "top level" Trellis/lattice function.
By "top-level", I mean a function like 'xyplot', 'histogram',
'bwplot', etc.
These functions all call 'trellis.skeleton', which I am unable to
call;
an attempt to invoke the function that does so yields the error
message:
-----
Error in do.call("trellis.skeleton",
2008 May 16
1
Lattice box percentile plot
Dear Nabble.
I am trying to draw a box percentile plot with trellis using the panel in
Hmisc. I really want to colour the plots in. I can alter several of features
of the plot by changing the trellis par settings but I just can’t fill the
shape in.
Here is some example code which alters line colour and dot symbol:
require(lattice)
require(Hmisc)
2012 Dec 11
2
lattice question: how to change the dot on boxplot to line
Hi,
How does one change the dot for the median in a boxplot drawn using
lattice? I have been looking at
> names(trellis.par.get())
[1] "grid.pars" "fontsize" "background"
[4] "panel.background" "clip" "add.line"
[7] "add.text" "plot.polygon"
2006 Mar 15
1
How to get correct proportions/bounding box for latex figure?
Hello,
I recently posted a question about my troubles with
importing
a lattice/trellis figure into latex.
To recap,
The figure contains 3 scatterplots, so it should have
roughly a 1:3 sort
of aspect ratio, in order to make each of the
scatterplots square.
Instead, the whole figure comes out roughly square, so
each scatterplot
is badly stretched. I fixed this by adding aspect=1/1
to the
2010 Jun 17
2
Multiple plots in a single page and stripplot()
I want to make a 2x2 plot on a single page, using stripplot() and boxplot().
I tried the following two alternatives with mfrow() and layout(), but none
of them worked.
library(lattice)
par(mfrow=c(2,2))
boxplot(X1 ~ Y, data=tst1, horizontal=T, las=1)
boxplot(X2 ~ Y, data=tst1, horizontal=T, las=1)
stripplot(Y ~ X1, data=tst1)
stripplot(Y ~ X2, data=tst1)
par(mfrow=c(1,1))
nf <-
2007 Jan 04
5
color of opposite sign values in filled.contour
Dear R-helpers,
I'm plotting geophysical data in the form of contours using
"filled.contour". The display would be much more effective if the areas
with negative values could be color coded
by -- say -- "cold colors" in the range of blue to green, and conversely
the areas with positive values got plotted with "warm colors", from yellow
to red.
Right now if I use
2006 Jul 19
2
trellis.focus with postscript device
Hello.
First: R 2.3.1 on Windows XP.
I am trying to add information (sample size) to the Trellis strips which
I am successful using the trellis.focus function with the default
Windows device. However, I typically use the postscript device as I use
LaTeX and \includegraphic for incorporating graphs into stat reviews.
Here's some example code (apologies for the lack of creativity and