Re: [R] print to .jpeg

2011-04-12 Thread Benjamin Caldwell
Luke, Just caught that myself. Thanks for the help, did the trick! *Ben Caldwell* On Tue, Apr 12, 2011 at 7:03 PM, Luke Miller wrote: > And of course I need to close the parentheses completely on jpeg(). > Apologies for the double post. > > jpeg(paste(species.name, '.jpg', sep = '')) > > > On

Re: [R] print to .jpeg

2011-04-12 Thread Henrik Bengtsson
Hi, First, don't use JPEG for your scientific plots - the image file format uses a compression that is really bad for anything but photos. Instead use PNGs. For scientific plots, PNG files are often also smaller than JPEG files, e.g. in your case the JPEG is ~4 times larger than the PNG. See also

Re: [R] print to .jpeg

2011-04-12 Thread Luke Miller
And of course I need to close the parentheses completely on jpeg(). Apologies for the double post. jpeg(paste(species.name, '.jpg', sep = '')) On Tue, Apr 12, 2011 at 10:02 PM, Luke Miller wrote: > How about using paste() inside the jpeg() function to append a '.jpg' to > the end of your specie

Re: [R] print to .jpeg

2011-04-12 Thread Luke Miller
How about using paste() inside the jpeg() function to append a '.jpg' to the end of your species name? See the change below. I also added a dev.off() to close the newly created jpeg. species.name="CussoniaHolstii" dia<-10:100 biomass = -21.4863 + 0.5797 * (dia ^ 2) biomass jpeg(paste(species.name,

[R] print to .jpeg

2011-04-12 Thread Benjamin Caldwell
Evening folks, I'm trying to print a series of graphs to .jpeg using a variable as the title, but run into the difficultly that I can't find a way to append the file extension to the .jpeg (in this case extensionless!) files. Example: species.name="CussoniaHolstii" dia<-10:100 biomass = -21.