Animations for Spatial Patterns (simulation only!)

THIS SITE IS STILL UNDER CONSTRUCTION. PLEASE COME BACK AFTER THIS NOTICE IS REMOVED. THANKS!

Sorry, it has been a long long time since I wrote the last blog entry... In the past few months, I was extremely busy with a lot of time-consuming affairs, and it seems that such a trend is not to change in near future.

A week ago, Ye Li wrote me an email, telling me his interests in my package animation. And his idea was to implement animations in spatio-temporal models to illustrate certain changes of patterns over time / space (say, clustering). Well, this sounds easy for me to create animations, however, I should know theories behind spatial statistics first of all -- that's much more difficult than the animation techniques and requires more efforts in study.

Here is a simple demonstration using the map of USA:

I just used the function saveMovie() in the package animation:

[notice type=download]Downdload the file here[/notice]

library(animation)
library(maps)
saveMovie(for (i in 1:20) map("state", col = sample(terrain.colors(30)),
    fill = TRUE), height = 300, width = 500, interval = 1, outdir = getwd())

Easy enough, huh?

Yihui Xie /
Published under (CC) BY-NC-SA in categories R language  tagged with Animation  GIF  Map  Spatial Statistics