# visualization

### Separation of degrees

January 20, 2012 |

Scientific American has a short article on trends in undergraduate degrees over the past 20 years, illustrated with a great infographic by Nathan Yau. As a big fan of STEM (science, tech, engineering and math) education, I was pleased to … Continue reading → [Read more...]

December 21, 2011 |

I wrote a little function to make a personalized map of who follows you or who you follow on Twitter. The idea for this function was inspired by some plots I discussed in a previous post. I also found a lot of really useful code over at flowing data he... [Read more...]

### Diagram for a Bernoulli process (using R)

November 10, 2011 |

A Bernoulli process is a sequence of Bernoulli trials (the realization of n binary random variables), taking two values (0/1, Heads/Tails, Boy/Girl, etc…). It is often used in teaching introductory probability/statistics classes about the binomial distribution. When visualizing a Bernoulli process, it is common to use a binary ... [Read more...]

### A New Dimension to Principal Components Analysis

October 27, 2011 |

In general, the standard practice for correcting for population stratification in genetic studies is to use principal components analysis (PCA) to categorize samples along different ethnic axes.  Price et al. published on this in 20...

### Mapping Hotspots with R: The GAM

October 25, 2011 |

I've been getting a lot of questions about the method used to map the hotspots in the seasonal drunk-driving risk maps.  It uses the GAM (Geographical Analysis Machine), a way of detecting spatial clusters from two data inputs: the data of interes...

### Shipping Mix

October 20, 2011 |

With a fresh pile of historical global shipping data, we came back to the flow visualizations that illustrated tangible supply lines that facilitate global trade.  This time we've isolated two types of shipping vessels, cargo and tanker, in order ...

### vectorplot in rasterVis

October 2, 2011 |

The function slopeAspect from raster provides the vector field (gradient) from a scalar field stored in a RasterLayer object. The magnitude (slope) and direction (aspect) of the vector field is usually displayed with a set of arrows (e.g. quiver in Matlab). rasterVis includes now a method, vectorplot, to calculate ... [Read more...]

### Create an animated clock in R with ggplot2 (and ffmpeg)

August 12, 2011 |

Because it’s Friday—and I needed to create this for a separate visualization—here is how to create an animated clock in R using ggplot2. In just about 20 lines of code! And here is the clock… I think this is a nifty way to show time elapse, rather than ... [Read more...]

July 30, 2011 |

This past Friday, the web portal to the US Federal government, USA.gov, organized hackathons across the US for programmers and data scientists to work with and analyze the data from their link-shortening service. It turns out that if you shorten a web link with bit.ly, the shortened link ... [Read more...]

### Scatterplot matrices in R

July 25, 2011 |

I just discovered a handy function in R to produce a scatterplot matrix of selected variables in a dataset. The base graphics function is pairs(). Producing these plots can be helpful in exploring your data, especially using the second method below.Try...

### rasterVis

July 6, 2011 |

The raster package defines classes and methods for spatial raster data access and manipulation. The new rasterVis package complements raster providing a set of methods for enhanced visualization and interaction. It is now at CRAN. Several examples can ... [Read more...]

### Raster, CMSAF and solaR

June 17, 2011 |

The Satellite Application Facility on Climate Monitoring (CMSAF) generates, archives and distributes widely recognised high-quality satellite-derived products and services relevant for climate monitoring in operational mode. The data is freely accesible here after a registration process. I have ask them for several files with monthly averages of global solar radiation ... [Read more...]

### Engineering Data Analysis (with R and ggplot2) – a Google Tech Talk given by Hadley Wickham

June 17, 2011 |

It appears that just days ago, Google Tech Talk released a new, one hour long, video of a presentation (from June 6, 2011) made by one of R’s community more influential contributors, Hadley Wickham. This seems to be one of the better talks to send a programmer friend who is interested ... [Read more...]

### Sustainable Futures conference in Manchester

May 2, 2011 |

Recently, Kevin Ummel gave a short conference about his PhD research at the Sustainable futures – Tyndall Centre researchers’ international conference. His work, named “Optimizing worldwide deployment of wind and solar power technologies via a high resolution, linear programming model”, is built with R. He is using the solaR package for ... [Read more...]

### Here comes the sun

May 1, 2011 |

The solar irradiance incident outside the earth’s atmosphere is called the extraterrestial or extra-atmospheric irradiance. It is derived from the solar constant only with geometric equations. It can be easily calculated with the calcSol function of the solaR package. With this post I will show an example with some ... [Read more...]

### Annotated Manhattan plots and QQ plots for GWAS using R, Revisited

April 25, 2011 |

Last year I showed you how to create manhattan plots, and later how to highlight regions of interest, using ggplot2 in R. The code was slow, required a lot of memory, and was difficult to maintain and modify. I finally found time to rewrite the code u... [Read more...]

### intuitive visualizations of categorization for non-technical audiences

April 25, 2011 |

For a project I’m working on at work, I’m building a predictive model that categorizes something (I can’t tell you what) into two bins. There is a default bin that 95% of the things belong to and a bin that the business cares a lot about, containing 5% of ... [Read more...]

### stalkR: R functions for exploring iPhone and iPad (OS X only)

April 21, 2011 |

Yesterday Alasdair Allan and Pete Warden shocked the world by revealing that iPhones and iPads have been keeping track of our every move, and saving the data in obfuscated back up files. As my friend Vince Buffalo mentioned on Twitter, part of me was disgusted by the secret stalking Steve ... [Read more...]

### Alpha shapes with R and lattice

April 7, 2011 |

What are the alpha shapes?: “The concept of alpha shapes formalizes the intuitive notion of “shape” for spatial point set data, which occurs frequently in the computational sciences. An alpha shape is a concrete geometric object that is uniquely defined for a particular point set.[...] Alpha shapes are generalizations of ... [Read more...]