Skip to content

How change the size of persp() axis labels?

9 messages · Gavin Simpson, Jason Turner, Peter Dalgaard +4 more

#
Hi,

I have been using the persp() function to plot species response surfaces
based on GAMs (using package mgcv).  Everything works fine, except that
I have a slight problem when it comes to producing a figure with
multiple (4 - 6) persp() plots on it.  The axis labels remain the same
size, no matter how large or small the plot is, causing some overlap
when the multiplot figure is produced.

Is there a way to reduce the size of the axis labels in persp() (either
for ticktypes="simple" or ticktypes="detailed")?

Ideally I would like to know how to reduce the size of the axis labels
when using ticktypes="detailed", and force persp() to plot only the min
and max value along each axis.  Is this possible?

R is running under Win2000.
_              
platform i386-pc-mingw32
arch     x86            
os       Win32          
system   x86, Win32     
status                  
major    1              
minor    3.1            
year     2001           
month    08             
day      31             
language R 

Many thanks

Gavin

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
#
I'm trying to remake R to use png on solaris.
I've installed the libpng and zlib packages,

	libpng-1.0.11-sol8-sparc-local
	zlib-1.1.3-sol8-sparc-local

and get this from ./configure

checking for png.h... (cached) yes
checking if libpng version >= 1.0.5... yes
checking for png_create_write_struct in -lpng... (cached) no
checking for XDR support... (cached) yes
checking for gzopen in -lz... (cached) yes
checking for zlib.h... (cached) yes
checking if zlib version >= 1.1.3... yes

after make and make check:  capabilities() still reports png FALSE.
I presume the problem is the "no" above, but I'm unclear what to do about it.
Any suggestions would be most welcome...for the record:
_
platform sparc-sun-solaris2.8
arch     sparc
os       solaris2.8
system   sparc, solaris2.8
status
major    1
minor    3.1
year     2001
month    08
day      31
language R

url:	http://www.econ.uiuc.edu		Roger Koenker
email	roger at ysidro.econ.uiuc.edu		Department of Economics
vox: 	217-333-4558				University of Illinois
fax:   	217-244-6678				Champaign, IL 61820




-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
#
...
...
Looks like you forgot a:  

rm config.cache

before your

./configure

The truly paranoid can rm -r the R-1.x.y directory structure, 
and untar the source again, but the above should work fine.

Cheers

Jason
#
Yes, as Robert Gentleman suggested moments after my question was posted
this was a problem of not removing the config.cache file.  I did a
make clean and then  rm config.cache and then everything built smoothly.
The resulting png files are very convenient particularly in the pdflatex
environment, thanks to Guido Masarotto and Brian Ripley for this.

Roger


url:	http://www.econ.uiuc.edu		Roger Koenker
email	roger at ysidro.econ.uiuc.edu		Department of Economics
vox: 	217-333-4558				University of Illinois
fax:   	217-244-6678				Champaign, IL 61820
On Thu, 25 Oct 2001, Jason Turner wrote:

            
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
#
Roger Koenker <roger at ysidro.econ.uiuc.edu> writes:
Um, no... 

PNG is a raster format. You'd likely be better off writing PDF
directly or using epstopdf on PostScript output.
#
On 25 Oct 2001, Peter Dalgaard BSA wrote:

            
Definitely better off with R's pdf() device unless you are really writing
raster images with image(), and possibly even then as pdftex handles
.pdf files better than .png ones.
#
Yes, I now agree.  I had had some trouble with postscript to pdf conversion
and had not tried the pdf() option, but it is now clear that either of
Peter's options are preferable to png() for what I wanted, which by the
way was pdflatex |ppower4 |acroread for projected slides.  Thanks to all
for the very helpful advice.


url:	http://www.econ.uiuc.edu		Roger Koenker
email	roger at ysidro.econ.uiuc.edu		Department of Economics
vox: 	217-333-4558				University of Illinois
fax:   	217-244-6678				Champaign, IL 61820
On Thu, 25 Oct 2001, Prof Brian Ripley wrote:

            
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
#
> Yes, I now agree.  I had had some trouble with postscript to pdf conversion
  > and had not tried the pdf() option, but it is now clear that either of
  > Peter's options are preferable to png() for what I wanted, which by the
  > way was pdflatex |ppower4 |acroread for projected slides.  Thanks to all
  > for the very helpful advice.

If it is for online presentations then there are some cases when png
is preferable to pdf: when you have scatter plots with LOTS of points
(several thousand, but that depends on your hardware), then acroread
can get very slow in rendering the figure (and some printers do run
out of memory when printing the PS) -> that's the only situation when
I prefer a bitmap to a vector graphic.

Best,
#
Another way to deal with graphics that are large ( e.g. images) is to save
them as postscript and then convert them to jpg format. I like using xv to
do this. The graphicx package with pdflatex supports this format for
figures.

Doug

-----------------------------------------------------------------------------
Doug Nychka,

Geophysical Statistics Project              Email: nychka at ucar.edu
National Center for Atmospheric Research    Voice: 303-497-1711
Climate and Global Dynamics Division          FAX: 303-497-1333
Boulder, CO  80307                            Web: www.cgd.ucar.edu/~nychka

Address for overnight mail: 1850 Table Mesa Drive, Boulder, CO 80305


-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._