Togaware DATA MINING
Desktop Survival Guide
by Graham Williams
Google

Making an Animation

Create 10 files of jpg

frames <- 10
for(i in 1:frames) 
{
  jpeg(sprintf("ani_%02d.jpg", i))
  plot(1:10, 1:10, col=i)
  dev.off()
}

Then use ImageMagick to transform to an animated gif:

system("convert -delay 10 ani_??.jpg animation.gif")



Copyright © 2004-2006 Graham.Williams@togaware.com
Support further development through the purchase of the PDF version of the book.
Brought to you by Togaware.