Mapping trees (and other things) after a long introduction on open (and unused?) data

Disclaimer: my primary intent was to share my new treemap, if you are not interested in why and how we make maps, you can just explore the treemap – preferably on Chrome -without reading the post below…
screen-shot-2017-01-13-at-10-18-37-amThe open data movement is gaining ground quickly, and there is now hardly any city without an open data website, as you can tell by looking at the updated overview of the US open data census . There is a deserved sense of accomplishment in the open data community, but Jonathan Stoneman accurately titled a recent article of his: “There is no shortage of open data. The question is, is anyone using it?”. To which we can also add: and is it possible to use it without spending an entire week cleaning the data and making sense of incongruous entries? To anyone who has worked with open data, has desired to do so or simply has showed interest in looking at the published data, this question resonates a lot.

Much progress have been made in improving data, and the guidelines of “good” data posting are widely known and slowly being enforced everywhere. Such guidelines can be found in the documentation of open data foundations such as the Sunlight foundation: “Open data isn’t just data that’s posted online — the census also notes if datasets are free, openly licensed, easy to download, accessible without restrictions and up to date”. Guidelines do not solely have advantages; because they generally give clear criteria on the definition of open datasets, some data portals will do the absolute minimum to change a red bar in the us census open data overview into a seemingly wonderful green bar. Indeed, objective criteria can never encompass all the properties that make a dataset truly usable for everybody. I am here stating the obvious, but this explains why so many open maps on data portals span from unreadable to just useless.

Cities can argue that their role is not to deliver a visual of the dataset, but the steps from the dataset to the visual output are often made strenuous because of the low data quality. In other words, if the datasets hosted on the city platforms can’t easily be transformed into a visual, there must be something wrong with the initial data. Companies like Tableau have specialized in easily exploring data sets, and some open data platforms point to that kind of tools, but would it not be a good idea to better integrate the tasks? If developers, researchers and citizens in general can immediately visualize open data sets, they might better trust the data and think of possible applications for it. How many times have I been excited by an open dataset’s title before discovering that the data was in fact untidy, patchy or/and simply lacked the attributes (longitudinal/geolocated/etc.) that I was expecting. Today, new directions involve showcases of user-made visualization to illustrate the potential of the data. These showcases depend, however, on an initial interest of the public, which is precisely what Jonathan Stoneman worries about.

I am being, I fear, a bit unfair to the constant and truly impressive progress in making data cleaner, more open and more easily visualized, but the comments above were simple observations I made while completing my most recent interactive map. Like many other people, I have grown more and more interested in tree canopies in cities, and have created a tree map for Seattle. This kind of map is nothing new and follows similar efforts in dozens and dozens of cities, including Seattle. Unfortunately, I have found that most of the maps were of no use for me. They did not give me a nice experience of data exploration or an incentive to use the dataset for academic research. The one made by the city of Seattle is an obvious example; you would only spend time on this map if you were looking for a specific piece of information.

screen-shot-2017-01-13-at-9-59-24-amCertainly aware of that, another Seattle Tree Map was created two years ago by the Seattle Audubon Society, and grants a special focus on how much energy, water, air quality, and greenhous gas benefits are gained each year thanks to the tree canopy. It also aims at gathering data from individuals (citizen science project). Unfortunately, the map is small and slow to load data between each click. In addition, as of January 17th 2017, the internet domain has apparently not been renewed and the map is therefore nowhere to be found.

screen-shot-2017-01-13-at-10-01-09-amAll these comments reflect the conclusion of the Computer Weekly article: “Without a fuller understanding of what users want from datastore APIs, the ‘web of data’ will be a long time coming”. It is true of maps as it is true from APIs: when delivering data (plotted or not), it needs to be tailored to the needs of the user. And, consequently, we need to say explicitly what needs these datasets were tailored to, even if we made a wrong analysis of these needs. This way we let the user know of the initial intent.

Coming back to my map, I made it to achieve a better completion of the science citizen project of the Seattle Audubon Society, which I found great and potentially extremely useful for a laboratory in urban ecology, such as the one I work in. Often researchers are not using open data because the data is incomplete. It is not because there is open data on a particular topic that it makes it usable for a research project, for which the exigence of data reliability is particularly high. Not enough trees are inventoried, which forces researchers to come up with new data collection ideas. It is for example what accomplished the Sensable Lab (MIT) when designing Treepedia, a comparison of green covers that takes Google Street View Images as an indicator of greenness, and by extension of tree cover.

screen-shot-2017-01-13-at-10-04-07-amFor my map, I want people curious about trees and the different species of trees to quickly gain information on the species. I want ‘walk lovers’ to spot where they will see their favorite trees and where they could add crucial information on the trees that are not inventoried. I want people to know about the uneven distribution of trees among neighborhoods, not only in terms of raw numbers, but also in terms of species. It could also help urban planners and landscape architects to make choices for future green spaces and future plantations. Where and what to plant, and therefore how unevenness of ecosystem services is fought or enforced, is a crucial issue in urban planning, as shows a recent article by Locke et al. entitled “What’s scale got to do with it? Models for urban tree canopy” and published in the journal of Urban Ecology. Of course I had to make lots of trade-offs when designing this map, and I would love to hear about suggestions to improve it. As other maps of this kind, it is generally better to open in Chrome.

I don’t know if people would be interested in knowing the technicalities behind that kind of map (they are made in a very similar fashion to the one of NYC for example), but I can share with you my work pipeline. I used Python scripts to download the GIS data from the Seattle City portal so that I could update the data easily on a regular basis. Still using Python scripts, I fed the data in a CartoDB database (its API gave me the best query time in comparison to a free Amazon Database and Webserver or my own university database) and I developed the website using Bootstrap and Leaflet. The clustering is done with the PruneCluster library instead of the Markercluster library because of rendering time issues (the former is more efficient than the later). Most of my work was in fact spent in complementing the city data; I researched all the genus, family and order corresponding to the trees and searched for websites that give useful information on each tree species. Some species are obviously extremely close to each other and filtering merely by species was a clear limitation. I will send my updated data to the city as it might be of interest for many people.

Because I use this blog very sporadically, I will take advantage of this post to point towards another recent (lower-scale) map that allows users to visualize and filter activity flows at a tract level using the D3 library. The mechanism can be used for any origin destination dataset along with a geojson file for the administrative units hence do not hesitate to adapt it for your own project. This map was designed and realized by Dylan Babbs and myself.
screen-shot-2017-01-13-at-10-16-35-amHave a wonderful year 2017.

You only sell to your neighbours – Spatial communities in football transfers

Communities from 1970

In this post, I use network analysis to show how transfers between football clubs create strong spatial patterns and divide England in two distinct communities. This means that there are very distinct regions in which transfers are being undertaken and between which there are few transfers. Continue reading →

Data: the open secret (Part 2)

Because there are so many initiatives, it is difficult to sort all the data created, and to understand the motives behind all the data collection and analyses. The « civic » part of the data – open data, crowdsourcing, data mining contests -, which was described in the first part, is only the tip of the iceberg, though a racing emerging tip. A huge part of the data is collected behind closed doors and we ignore that it even exists and is used, despite the increasing attention from the media (the cover below – dated from 5 years ago! – is an example among many).

Figure 1:  The Economist cover, March 2010
Figure 1: The Economist cover, March 2010

 

Continue reading →

There is something else than JCDecaux and Barclays

Bike-sharing systems have been the first new transit hype of the XXIst century, the countries having implemented such programs raising from 6 in 2000 to 49 in 2013 (cf Figure 1). Our knowledge of them has remarkably increased and researchers everywhere in the world are still working on new algorithms to improve the efficiency of the system. Where should the stations be localized? How can we move the bikes from a station to the other so that there is never an empty or full station? What is the perfect size of a station? Will we have bikes that move by themselves from a full station to an empty station? The “JCDecaux” economic model, based on advertising partnerships, has also been thoroughly studied.

Capture d’écran 2015-02-03 à 15.37.59

Figure 1: from http://www.earth-policy.org/plan_b_updates/2013/update112

Comparatively, very little has been said about the type of governance for the bike-sharing systems.

Continue reading →

About the importance of looking beyond data

Sometimes we encounter articles that use data as if they exempted the authors from explaining their assumptions about cities. When it comes to urban problems, the solutions to tackle them are numerous and not always compatible. It explains why there are so many different theories about which scholars, urban leaders, practitioners, etc., argue most of the time. Let’s consider transport for example. There is not one straightforward answer to the following questions: How should public transit be financed? What is a good fare for citizens in order to foster efficient public transit? What is, precisely, an efficient public transit?

Continue reading →

The Sharing City: disillusion or opportunity for better regulation?

Like other promising social trends before, the Sharing City seems to have slid down in the hype cycle, where it is now stuck in the trough of disillusion. A few years ago, the prospects of car sharing, of renting a place in any city of the world, of renting a car between individuals, and all of that at a very reasonable price, were appealing to everybody. Last September, Julian Agyeman, a professor at Tufts university, summed up this hope in the Time (http://time.com/3446050/smart-cities-should-mean-sharing-cities/):

 ‘Sharing the whole city’ should become the guiding purpose of the future city. (…) It redefines what ‘smart cities’ of the future might really mean—harnessing smart technology to an agenda of sharing and solidarity, rather than the dumb approaches of competition, enclosure and division.

Alas, since, most of us have taken a ride in a overfilled minivan or have spent a night in an Airbnb apartment looking exactly like a soulless hotel room, the filth in bonus.

Continue reading →