Re: [R] Odd graphics output problem

2010-09-16 Thread RICHARD M. HEIBERGER
See the FAQ 7.22 Why do lattice/trellis graphics not work?

The most likely reason is that you forgot to tell R to display the graph.
Lattice functions such as xyplot() create a graph object, but do not display
it (the same is true of
*ggplot2*http://cran.r-project.org/package=ggplot2graphics, and
Trellis graphics in
S-Plus). The print() method for the graph object produces the actual
display. When you use these functions interactively at the command line, the
result is automatically printed, but in source() or inside your own
functions you will need an explicit print() statement.

On Thu, Sep 16, 2010 at 10:34 AM, David Warren
davideugenewar...@gmail.comwrote:

 Hi all,

 I'm having trouble saving graphics output from within a loop, and I
 can't figure out a solution.  I'd like to produce and save lots of
 individual plots for inspection, so I set up the following script:


[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list
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.


Re: [R] Odd graphics output problem

2010-09-16 Thread David Warren
Got it, thanks!

On Thu, Sep 16, 2010 at 10:22 AM, RICHARD M. HEIBERGER r...@temple.eduwrote:

 See the FAQ 7.22 Why do lattice/trellis graphics not work?

 The most likely reason is that you forgot to tell R to display the graph.
 Lattice functions such as xyplot() create a graph object, but do not
 display it (the same is true of 
 *ggplot2*http://cran.r-project.org/package=ggplot2graphics, and Trellis 
 graphics in
 S-Plus). The print() method for the graph object produces the actual
 display. When you use these functions interactively at the command line, the
 result is automatically printed, but in source() or inside your own
 functions you will need an explicit print() statement.

 On Thu, Sep 16, 2010 at 10:34 AM, David Warren 
 davideugenewar...@gmail.com wrote:

 Hi all,

 I'm having trouble saving graphics output from within a loop, and I
 can't figure out a solution.  I'd like to produce and save lots of
 individual plots for inspection, so I set up the following script:




-- 
Post-doctoral Fellow
Neurology Department
University of Iowa Hospitals and Clinics
davideugenewar...@gmail.com

[[alternative HTML version deleted]]

__
R-help@r-project.org mailing list
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.