local version for http://bl.ocks.org/benzguo/4370043