<p><div><div><div><div data-width="100" data-show-faces="false" data-send="true" data-layout="button_count" data-height="21" data-href="https://www.r-bloggers.com/watch-the-world-warm-with-this-animated-globe-created-with-r/"></div></div><div><a data-url="https://www.r-bloggers.com/watch-the-world-warm-with-this-animated-globe-created-with-r/" data-counturl="https://www.r-bloggers.com/watch-the-world-warm-with-this-animated-globe-created-with-r/" data-count="horizontal" data-text="Watch the world warm with this animated globe, created with R" class="twitter-share-button" data-via="rbloggers" href="https://twitter.com/share"></a></div><div></div></div><div></div></div>
<div>
(This article was first published on <strong><a href="http://blog.revolutionanalytics.com/2016/10/warming-globe.html"> Revolutions</a></strong>, and kindly contributed to <a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers)</a> </div>
<div>
<p>Due to anthropogenic climate change, the average global temperature has increased steadily over the past decade or so. While we're all familiar with the hockey-stick line chart of rising temperature, the change is even more dramatic on this <a target="_blank" href="https://blog.snap.uaf.edu/2016/10/10/animate-maps-with-mapmate-r-package-for-map-and-globe-based-still-image-sequences">animated globe showing the <em>local</em> effects of climate change</a>.</p>
<p><iframe height="281" allowfullscreen="" width="500" src="https://www.youtube.com/embed/xhqEkyJDBho?rel=0"></iframe></p>
<p>The first half of the animation shows the monthly local change compared to historic averages (blue is cooler; red is warmer). The second half of the animation repeats the cycle, but introduces a moving 10-year smoother to reduce the variability in the temperature changes, making the global temperature increase much more apparent in the forecast part of the animation. The overlaid time series shows the global average temperatue deviations from the historical average, in degrees Celcius.</p>
<p>This animation was created by Matt Leonawicz, Lead Statistical Analyst at the <a target="_blank" href="https://www.snap.uaf.edu/">Scenarios Network for Alaska and Arctic Planning</a>, using the <a target="_blank" href="https://mran.microsoft.com/documents/what-is-r/">R language</a>. He created a custom R package called &quot;mapmate&quot; (<a target="_blank" href="https://github.com/leonawicz/mapmate">available on Github</a>) to convert tile-based flat maps like this:</p>
<p><a target="_blank" href="http://revolution-computing.typepad.com/.a/6a010534b1db25970b01b8d22886f8970c-pi"><img title="Mapmate1" alt="Mapmate1" src="http://revolution-computing.typepad.com/.a/6a010534b1db25970b01b8d22886f8970c-800wi" border="0"></a></p>
<p>and converts them into a globe projection at a selected angle of view, like this:</p>
<p><a target="_blank" href="http://revolution-computing.typepad.com/.a/6a010534b1db25970b01b7c89ebe58970b-pi"><img title="Mapmate2" alt="Mapmate2" src="http://revolution-computing.typepad.com/.a/6a010534b1db25970b01b7c89ebe58970b-800wi" border="0"></a></p>
<p>The package also automates the process of creating and saving the frames of an animation for later assembly in a video-production tool. For this animation, Matt made extensive use of the <a target="_blank" href="https://www.rdocumentation.org/packages/purrr/versions/0.2.2/topics/map">walk</a> function from the purrr package to cycle through the different viewing angles needed in each frame to make the globe rotate in the video. The computations can be quite time consuming, but Matt used a 32-CPU Linux server and the <code>mclapply</code> function to process frames in parallel and speed up the process. </p>
<p>For more on the animation and how it was created, read Matt's detailed post linked below.</p>
<p>SNAP Tech: <a target="_blank" href="https://blog.snap.uaf.edu/2016/10/10/animate-maps-with-mapmate-r-package-for-map-and-globe-based-still-image-sequences/">Animate maps with mapmate: R package for map- and globe-based still image sequences</a></p>
</div>
<p><div><div><div><div data-width="55" data-show-faces="false" data-send="true" data-layout="box_count" data-height="62" data-href="https://www.r-bloggers.com/watch-the-world-warm-with-this-animated-globe-created-with-r/"></div></div><div><a data-url="https://www.r-bloggers.com/watch-the-world-warm-with-this-animated-globe-created-with-r/" data-counturl="https://www.r-bloggers.com/watch-the-world-warm-with-this-animated-globe-created-with-r/" data-count="vertical" data-text="Watch the world warm with this animated globe, created with R" class="twitter-share-button" data-via="rbloggers" href="https://twitter.com/share"></a></div><div></div></div><div></div></div>
<div>
<div>To <strong>leave a comment</strong> for the author, please follow the link and comment on their blog: <strong><a href="http://blog.revolutionanalytics.com/2016/10/warming-globe.html"> Revolutions</a></strong>.</div>
<hr>
<a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers.com</a> offers <strong><a rel="nofollow" href="https://feedburner.google.com/fb/a/mailverify?uri=RBloggers">daily e-mail updates</a></strong> about <a title="The R Project for Statistical Computing" rel="nofollow" href="https://www.r-project.org/">R</a> news and <a title="R tutorials" rel="nofollow" href="https://www.r-bloggers.com/?s=tutorial">tutorials</a> on topics such as: <a title="Data science" rel="nofollow" href="https://www.r-bloggers.com/?s=data%20science">Data science</a>, <a title="Big Data" rel="nofollow" href="https://www.r-bloggers.com/?s=Big%20Data">Big Data, <a title="R jobs" rel="nofollow" href="https://www.r-users.com/">R jobs</a>, visualization (<a title="ggplot and ggplot2 tutorials" rel="nofollow" href="https://www.r-bloggers.com/?s=ggplot2">ggplot2</a>, <a title="Boxplots using lattice and ggplot2 tutorials" rel="nofollow" href="https://www.r-bloggers.com/?s=boxplot">Boxplots</a>, <a title="Maps and gis" rel="nofollow" href="https://www.r-bloggers.com/?s=map">maps</a>, <a title="Animation in R" rel="nofollow" href="https://www.r-bloggers.com/?s=animation">animation</a>), programming (<a title="RStudio IDE for R" rel="nofollow" href="https://www.r-bloggers.com/?s=RStudio">RStudio</a>, <a title="Sweave and literate programming" rel="nofollow" href="https://www.r-bloggers.com/?s=sweave">Sweave</a>, <a title="LaTeX in R" rel="nofollow" href="https://www.r-bloggers.com/?s=LaTeX">LaTeX</a>, <a title="SQL and databases" rel="nofollow" href="https://www.r-bloggers.com/?s=SQL">SQL</a>, <a title="Eclipse IDE for R" rel="nofollow" href="https://www.r-bloggers.com/?s=eclipse">Eclipse</a>, <a title="git and github, Version Control System" rel="nofollow" href="https://www.r-bloggers.com/?s=git">git</a>, <a title="Large data in R using Hadoop" rel="nofollow" href="https://www.r-bloggers.com/?s=hadoop">hadoop</a>, <a title="Web Scraping of google, facebook, yahoo, twitter and more using R" rel="nofollow" href="https://www.r-bloggers.com/?s=Web+Scraping">Web Scraping</a>) statistics (<a title="Regressions and ANOVA analysis tutorials" rel="nofollow" href="https://www.r-bloggers.com/?s=regression">regression</a>, <a title="principal component analysis tutorial" rel="nofollow" href="https://www.r-bloggers.com/?s=PCA">PCA</a>, <a title="Time series" rel="nofollow" href="https://www.r-bloggers.com/?s=time+series">time series</a>, <a title="finance trading" rel="nofollow" href="https://www.r-bloggers.com/?s=trading">trading</a>) and more...
<img height="1" alt="" width="1" src="http://feeds.feedburner.com/~r/RBloggers/~4/u8gqApBv7lc"></a></div>